📁 PHP Dosya Yöneticisi
/
/
home
/
demodesigncom
/
qrmenuscripti.demodesign.com.tr
/
yedekgüncel
📝
yeni_sip.php
← Geri Dön
<?php use PHPMailer\PHPMailer\PHPMailer; use PHPMailer\PHPMailer\Exception; require 'PHPMailer/src/Exception.php'; require 'PHPMailer/src/PHPMailer.php'; require 'PHPMailer/src/SMTP.php'; session_start(); include 'xpanel/inc/vt.php'; include 'xpanel/inc/smsyolla.php'; $secilen_adres=$_POST['adressec']; $smtp_settings = $dbh -> prepare("SELECT * FROM smtp_settings WHERE id = ?"); $smtp_settings-> execute(array(1)); $smtp_settings = $smtp_settings->fetch(PDO::FETCH_OBJ); $ayar = $dbh->query("SELECT * FROM general_settings WHERE id = 1 ", PDO::FETCH_ASSOC); if ($ayar->rowCount()) { foreach ($ayar as $ayar) { } } if(empty($_SESSION['user']->id)){ $user=0; }else{ $user=$_SESSION['user']->id; } if(count($_SESSION['sepet']) == 0){ $output = ['t'=>'Hata','m'=>'Sepetinizde Ürün yok','s'=>'error']; echo json_encode($output); exit(); } $zamanlar = $dbh -> prepare("SELECT * FROM calisma_saat WHERE id = ?"); $zamanlar-> execute(array(date('w'))); $zamanlar = $zamanlar->fetch(PDO::FETCH_OBJ); $teslimattarih = $_POST['teslimattarih']; /*en kısa süre 0 - diğer 1*/ $tip = $_POST['siptip']; /* paket - masa*/ $teslimat = $_POST['teslimat'];/*1 gelal 0 Adrese Teslim*/ if($tip=="paket" && $teslimattarih==1 && (empty($_POST['teslimtarih']) || empty($_POST['teslimsaat']))){ $output = ['t'=>'Bilgi','m'=>"Lütfen Saat ve Tarih Seçiniz",'s'=>'info']; echo json_encode($output); exit(); } if($tip=="paket" && $_POST['teslimat']==0 && (empty($_POST['mah']) || empty($_POST['adres']) || empty($_POST['sehir']) || empty($_POST['ilce']) )){ $output = ['t'=>'Bilgi','m'=>"Lütfen Adres seçiniz",'s'=>'info']; echo json_encode($output); exit(); } if($tip=="paket" && $zamanlar->paket_gon==0 && $teslimat==0 && $teslimattarih==0 ){ $output = ['t'=>'Bilgi','m'=>"Paket Servisimiz $zamanlar->gun günü için Çalışmamaktadır",'s'=>'info']; echo json_encode($output); exit(); } if($tip=="paket" && $zamanlar->acik==0 && $teslimat==1 && $teslimattarih==0){ $output = ['t'=>'Bilgi','m'=>"Restaurantımız $zamanlar->gun günü için Çalışmamaktadır",'s'=>'info']; echo json_encode($output); exit(); } $saaty=date('H:i:s'); if($tip=="paket" && $teslimattarih==0 && $zamanlar->acik==1 && $teslimat==1 && ( $zamanlar->acilis>=$saaty || $zamanlar->kapanis<=$saaty)) { $output = ['t'=>'Bilgi','m'=> "Restaurantımız $zamanlar->gun günü için $zamanlar->acilis - $zamanlar->kapanis Saatleri Arasında Çalışmaktadır",'s'=>'info']; echo json_encode($output); exit(); } if($tip=="paket" && $teslimattarih==0 && $zamanlar->acik==1 && $teslimat==0 && $zamanlar->paket_gon==1 && $saaty<="12:00" && $zamanlar->paket_bas<=$saaty && $zamanlar->paket_bitis>=$saaty ) { }elseif($tip=="paket" && $teslimattarih==0 && $zamanlar->acik==1 && $teslimat==0 && $zamanlar->paket_gon==1 && $saaty>="12:00" && $zamanlar->paket_bas2<=$saaty && $zamanlar->paket_bitis2>=$saaty ){ }elseif($tip=="paket" && $teslimattarih==0 && $zamanlar->acik==1 && $teslimat==0 && $zamanlar->paket_gon==1){ $output = ['t'=>'Bilgi','m'=> "Paket Servisimiz $zamanlar->gun günü için $zamanlar->paket_bas - $zamanlar->paket_bitis & $zamanlar->paket_bas2 - $zamanlar->paket_bitis2 Saatleri Arasında Yapılamaktadır.. $saaty",'s'=>'info']; echo json_encode($output); exit(); } if($tip=="paket" && $teslimattarih==1 && $teslimat==0){ $gun=date('w',strtotime($_POST['teslimtarih'])); $bugun=date('Y-m-d'); $saatye=date('H:i:s'); $saatyek=date('H:i:s',strtotime("-5 minutes")); $gelen=$_POST['teslimtarih']; $saatgelen=date('H:i:s',strtotime($_POST['teslimsaat'])); if($gelen==$bugun && $saatgelen<=$saatyek ){ $output = ['t'=>'Bilgi ','m'=>"Lütfen ileri bir zaman seçiniz $saatgelen $saatye .",'s'=>'info']; echo json_encode($output); exit(); } $kontt = $dbh -> prepare("SELECT * FROM calisma_saat WHERE id = ?"); $kontt-> execute(array($gun)); $kontt = $kontt->fetch(PDO::FETCH_OBJ); if($kontt->paket_gon==0 && $teslimat==0){ $output = ['t'=>'Bilgi','m'=>"Paket Servisimiz $kontt->gun günü için Çalışmamaktadır.",'s'=>'info']; echo json_encode($output); exit(); }else{ $saat = $_POST['teslimsaat']; if($saat<="12:00" && $kontt->paket_bas<=$saat && $kontt->paket_bitis>=$saat && $kontt->paket_gon==1 ){ }elseif($saat>="12:00" && $kontt->paket_bas2<=$saat && $kontt->paket_bitis2>=$saat && $kontt->paket_gon==1 ){ }else{ $output = ['t'=>'Bilgi','m'=> "Paket Servisimiz $kontt->gun günü için $kontt->paket_bas - $kontt->paket_bitis & $kontt->paket_bas2 - $kontt->paket_bitis2 Saatleri Arasında Yapılamaktadır",'s'=>'info']; echo json_encode($output); exit(); } } } if($tip=="paket" && $teslimattarih==1 && $teslimat==1){ $gun=date('w',strtotime($_POST['teslimtarih'])); $bugun=date('Y-m-d'); $saatye=date('H:i:s'); $saatyek=date('H:i:s',strtotime("-5 minutes")); $gelen=$_POST['teslimtarih']; $saatgelen=date('H:i:s',strtotime($_POST['teslimsaat'])); if($gelen==$bugun && $saatgelen<=$saatyek ){ $output = ['t'=>'Bilgi ','m'=>"Lütfen ileri bir zaman seçiniz $saatgelen $saatye",'s'=>'info']; echo json_encode($output); exit(); } $kontt = $dbh -> prepare("SELECT * FROM calisma_saat WHERE id = ?"); $kontt-> execute(array($gun)); $kontt = $kontt->fetch(PDO::FETCH_OBJ); if($kontt->acik==0 && $teslimat==1){ $output = ['t'=>'Bilgi','m'=>"Restaurantımız $kontt->gun günü için Çalışmamaktadır ",'s'=>'info']; echo json_encode($output); exit(); }else{ $saat=date('H:i:s',strtotime($_POST['teslimsaat'])); if($tip=="paket" && $teslimattarih==1 && $kontt->acik==1 && $teslimat==1 && $kontt->acilis>$saat) { $output = ['t'=>'Bilgi','m'=> "Restaurantımız $kontt->gun günü için $kontt->acilis - $kontt->kapanis Saatleri Arasında Çalışmaktadır!",'s'=>'info']; echo json_encode($output); exit(); }elseif($tip=="paket" && $teslimattarih==1 && $kontt->acik==1 && $teslimat==1 && $kontt->kapanis<$saat) { $output = ['t'=>'Bilgi','m'=> "Restaurantımız $kontt->gun günü için $kontt->acilis - $kontt->kapanis Saatleri Arasında Çalışmaktadır!",'s'=>'info']; echo json_encode($output); exit(); }else{ } } } if($_POST['siptip']=="masa" ){ $adisoyadi = strip_tags($_POST['adisoyadi']); $telefon = strip_tags($_POST['telefon']); $masa = $_POST['masa_adi']; $teslimat = $_POST['teslimat']; $payment = ($_POST['paymentm']); $durum = 0; if(empty($_SESSION["masa_no"])){ $output = ['t'=>'Hata','m'=>'Lütfen QR Okutunuz','s'=>'error']; echo json_encode($output); exit(); } if(count($_SESSION['sepet']) > 0){ $toplam2=0; foreach ($_SESSION['sepet'] as $siparis => $siparisdetay) { $array=$siparisdetay; $urun_getir = $dbh -> prepare("SELECT * FROM product WHERE id = ?"); $urun_getir-> execute(array($siparisdetay["urunid"])); $urun = $urun_getir->fetch(PDO::FETCH_ASSOC); $fiyat = $urun["product_price"]; $ekstraistek=0; $porsyon=""; $pfiyat=0; if($siparisdetay["menu_porsiyon"]>0){ $porsyon = $dbh -> prepare("SELECT * FROM product_portion WHERE id = ?"); $porsyon-> execute(array($siparisdetay["menu_porsiyon"])); $porsyon = $porsyon->fetch(PDO::FETCH_ASSOC); $key= array_search($siparisdetay["menu_porsiyon"],json_decode($urun['product_portion']) ); $porsiyonfler=json_decode($urun['product_portion_price']) ; $pfiyat= $porsiyonfler[$key]; } if($siparisdetay["ekstra"]){ $ekstralara=" "; $eksftop=0; foreach ($siparisdetay["ekstra"] as $eks) { $ekstrad = $dbh -> prepare("SELECT * FROM selectable WHERE id = ?"); $ekstrad-> execute(array($eks)); $ekstrad = $ekstrad->fetch(PDO::FETCH_ASSOC); $key= array_search($eks,json_decode($urun['product_optionek']) ); $ekstrafiyat=json_decode($urun['product_optionek_price']) ; $ekfiyat= $ekstrafiyat[$key]; $eksftop+=$ekfiyat; } } $toplam = ($fiyat + $pfiyat + $eksftop)*$array['qty']; $toplam2 += $toplam; if($_SESSION['indirim']){ $kodkontrol = $dbh -> prepare("SELECT * FROM coupon WHERE coupon_code = ?"); $kodkontrol-> execute(array($_SESSION['indirim'])); $kodkontrol = $kodkontrol->fetch(PDO::FETCH_OBJ); $toplam2 =$toplam2-$kodkontrol->discount_amount; } } $siparis_ekle = $dbh->prepare("INSERT INTO product_orders SET uye=?,adi_soyadi=?,telefon=?,masa=?,sip=?,payment=?,odeme_durum=?,durum=?,teslimat=?,amount=?,coupon=? "); $siparis_ekle-> execute(array($user,$adisoyadi,$telefon,$_SESSION["masa_no"],json_encode($_SESSION['sepet']),$payment,0,$durum,$teslimat,$toplam2,$_SESSION['indirim'])); if ($siparis_ekle) { // echo 'siparisiniz alindi'; $_SESSION['sipid'][]= $dbh->lastInsertId(); $_SESSION['sonsip']= $dbh->lastInsertId(); if( $payment=="kart"){ $output = ["t"=>"","m"=>"Sipariş Başarılı Yönlendiriliyorsunuz.","s"=>"success","r"=>"online-odeme"]; echo json_encode($output); }else{ $output = ["t"=>"","m"=>"Sipariş Başarılı Yönlendiriliyorsunuz.","s"=>"success","r"=>"siparis-alindi"]; echo json_encode($output); } $_SESSION['sepet']=[]; $_SESSION['indirim']=""; }else{ $output = ['t'=>'Hata','m'=>'Hata Oluştu','s'=>'error']; echo json_encode($output); } }else{ $output = ['t'=>'Hata','m'=>'Sepetinizde Ürün yok','s'=>'error']; echo json_encode($output); } }elseif($_POST['siptip']=="paket" ){ $adisoyadi = strip_tags($_POST['adisoyadi']); $telefon = strip_tags($_POST['telefon']); $mail = strip_tags($_POST['mail']); $sokak = strip_tags($_POST['adres']); $sehir = strip_tags($_POST['sehir']); $ilce = strip_tags($_POST['ilce']); $mah = strip_tags($_POST['mah']); $payment = ($_POST['payment']); $teslimat = $_POST['teslimat']; $teslimattarih = $_POST['teslimattarih']; $durum = 0; $sehird = $dbh -> prepare("SELECT * FROM sehir WHERE sehir_key = ?"); $sehird-> execute(array($sehir)); $sehird = $sehird->fetch(PDO::FETCH_OBJ); $ilced = $dbh -> prepare("SELECT * FROM ilce WHERE ilce_key = ?"); $ilced-> execute(array($ilce)); $ilced = $ilced->fetch(PDO::FETCH_OBJ); $adres =$sehird->sehir_title." / ".$ilced->ilce_title ." - " .$sokak ; if($payment=="kapida"){$odememail="Kapıda Ödeme";}else{$odememail="Online Ödeme";} if($teslimattarih==1){ $teslim = $_POST['teslimtarih'] ." / ". $_POST['teslimsaat']; }else{ $teslim=0; } $mahk = $dbh -> prepare("SELECT * FROM mahalle where mahalle_key=?"); $mahk-> execute(array($mah)); $mahk = $mahk->fetch(PDO::FETCH_OBJ); $toplamtutar=0; foreach ($_SESSION['sepet'] as $siparis => $siparisdetay) { $array=$siparisdetay; $urun_getir = $dbh -> prepare("SELECT * FROM product WHERE id = ?"); $urun_getir-> execute(array($siparisdetay["urunid"])); $urun = $urun_getir->fetch(PDO::FETCH_ASSOC); $fiyat = $urun["product_price"]; $ekstraistek=0; $porsyon=""; $pfiyat=0; if($siparisdetay["menu_porsiyon"]>0){ $porsyon = $dbh -> prepare("SELECT * FROM product_portion WHERE id = ?"); $porsyon-> execute(array($siparisdetay["menu_porsiyon"])); $porsyon = $porsyon->fetch(PDO::FETCH_ASSOC); $key= array_search($siparisdetay["menu_porsiyon"],json_decode($urun['product_portion']) ); $porsiyonfler=json_decode($urun['product_portion_price']) ; $pfiyat= $porsiyonfler[$key]; } if($siparisdetay["ekstra"]){ $ekstralara=" "; $eksftop=0; foreach ($siparisdetay["ekstra"] as $eks) { $ekstrad = $dbh -> prepare("SELECT * FROM selectable WHERE id = ?"); $ekstrad-> execute(array($eks)); $ekstrad = $ekstrad->fetch(PDO::FETCH_ASSOC); $key= array_search($eks,json_decode($urun['product_optionek']) ); $ekstrafiyat=json_decode($urun['product_optionek_price']) ; $ekfiyat= $ekstrafiyat[$key]; $eksftop+=$ekfiyat; if($ekfiyat>0){ $ekstralara.= $ekstrad['option']." ".$ekfiyat."₺ / "; }else{ $ekstralara.= $ekstrad['option']." / "; } } $ekstralara=rtrim($ekstralara," / " ); } $toplam = ($fiyat + $pfiyat + $eksftop)*$array['qty']; $urun = cevir("menu",$urun,$_SESSION["dil"]); $toplamtutar += $toplam; $porsyon = cevir("porsiyon_secenekleri",$porsyon,$_SESSION["dil"]); if($porsyon['portion']){ $porss="/ ".$porsyon['portion'];}else{$porss="";} $degerler.=$siparisdetay['qty']."x ".$urun['product_name']." ".$porss." + ".$ekstralara." = ".$toplam."TL<br>"; } if($toplamtutar>=$mahk->tutar || $_POST['teslimat']==1){ if($_SESSION['indirim']){ $kodkontrol = $dbh -> prepare("SELECT * FROM coupon WHERE coupon_code = ?"); $kodkontrol-> execute(array($_SESSION['indirim'])); $kodkontrol = $kodkontrol->fetch(PDO::FETCH_OBJ); $toplamtutar =$toplamtutar-$kodkontrol->discount_amount; } $siparis_ekle = $dbh->prepare("INSERT INTO product_orders SET uye=?,adi_soyadi=?,telefon=?,mail=?,mah=?,adres=?,masa=?,sip=?,payment=?,odeme_durum=?,durum=?,teslimat=?,teslimattarih=?,amount=?,coupon=?"); $siparis_ekle-> execute(array($user,$adisoyadi,$telefon,$mail,$mah,$adres,0,json_encode($_SESSION['sepet']),$payment,0,$durum,$teslimat,$teslim,$toplamtutar,$_SESSION['indirim'])); if ($siparis_ekle) { if($secilen_adres=="ekleadres"){ $baslik =$_POST['adresbaslik']; $sehir =$_POST['sehir']; $ilce =$_POST['ilce']; $mah =$_POST['mah']; $adres =$_POST['adres']; $satir = [ 'uye' => $_SESSION['user']->id, 'sehir' => $sehir, 'ilce' => $ilce, 'mah' => $mah, 'baslik' => $baslik, 'adress' => $adres, ]; $sql = "INSERT INTO users_adress SET uye=:uye ,baslik=:baslik, sehir=:sehir, ilce=:ilce , mah=:mah ,adress=:adress;"; $durum = $dbh->prepare($sql)->execute($satir); } $mailonay=1; $_SESSION['sonsip']= $dbh->lastInsertId(); $_SESSION['sipid'][]= $dbh->lastInsertId(); $_SESSION['mail']=$mail ; if( $payment=="kart"){ $output = ["t"=>"","m"=>"Sipariş Başarılı Yönlendiriliyorsunuz.","s"=>"success","r"=>"online-odeme"]; echo json_encode($output); }else{ $output = ["t"=>"","m"=>"Sipariş Başarılı Yönlendiriliyorsunuz.","s"=>"success","r"=>"siparis-alindi"]; echo json_encode($output); } $_SESSION['sepet']=[]; $_SESSION['indirim']=""; } }else{ $output = ['t'=>'Bilgi','m'=>"$mahk->mahalle_title İçin Min tutar $mahk->tutar TL olmalıdır",'s'=>'info']; echo json_encode($output); } } if($sms_setting->sip_alindi==1){ smsyolla($telefon,'Degerli kullanici siparisiniz alinmistir, Bizi tercih ettiginiz icin tesekkür ederiz. '); } if($mailonay==1){ $mailm= '<!DOCTYPE html> <html lang="tr" xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="x-apple-disable-message-reformatting"> <title>Siparişiniz Alındı</title> <link href="https://fonts.googleapis.com/css?family=Open+Sans:300,300i,400,400i,600,600i,700,700i,800,800i" rel="stylesheet"> <style> html, body { margin: 0 auto !important; padding: 0 !important; height: 100% !important; width: 100% !important; } * { -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; } div[style*="margin: 16px 0"] { margin:0 !important; } table, td { mso-table-lspace: 0pt !important; mso-table-rspace: 0pt !important; } table { border-spacing: 0 !important; border-collapse: collapse !important; table-layout: fixed !important; margin: 0 auto !important; } table table table { table-layout: auto; } img { -ms-interpolation-mode:bicubic; } *[x-apple-data-detectors], .x-gmail-data-detectors, .x-gmail-data-detectors *, .aBn { border-bottom: 0 !important; cursor: default !important; color: inherit !important; text-decoration: none !important; font-size: inherit !important; font-family: inherit !important; font-weight: inherit !important; line-height: inherit !important; } .a6S { display: none !important; opacity: 0.01 !important; } img.g-img + div { display:none !important; } .button-link { text-decoration: none !important; } @media only screen and (min-device-width: 375px) and (max-device-width: 413px) { .email-container { min-width: 375px !important; } } </style> <style> .button-td, .button-a { transition: all 100ms ease-in; } .button-td:hover, .button-a:hover { background: #555555 !important; border-color: #555555 !important; } @media screen and (max-width: 480px) { .fluid { width: 100% !important; max-width: 100% !important; height: auto !important; margin-left: auto !important; margin-right: auto !important; } .stack-column, .stack-column-center { display: block !important; width: 100% !important; max-width: 100% !important; direction: ltr !important; } .stack-column-center { text-align: center !important; } .center-on-narrow { text-align: center !important; display: block !important; margin-left: auto !important; margin-right: auto !important; float: none !important; } table.center-on-narrow { display: inline-block !important; } .email-container p { font-size: 17px !important; line-height: 22px !important; } } </style> </head> <body width="100%" bgcolor="#F1F1F1" style="margin: 0; mso-line-height-rule: exactly;"> <center style="width: 100%; background: #F1F1F1; text-align: left;"> <div style="max-width: 680px; margin: auto;" class="email-container"> <table role="presentation" cellspacing="0" cellpadding="0" border="0" align="center" width="100%" style="max-width: 680px;" class="email-container"> <tr> <td bgcolor="#17A2B8"> <table role="presentation" cellspacing="0" cellpadding="0" border="0" width="100%"> <tr> <td style="padding: 30px 40px 30px 40px; text-align: center;" align="center"> <img src="'.$ayar["web_adress"].'/img/'.$ayar["foto"].'" alt="alt_text" border="0" style="height: auto; font-family: sans-serif; font-size: 15px; line-height: 20px; color: #555555;"> </td> </tr> </table> </td> </tr> <tr> <td background="background.png" bgcolor="#222222" align="center" valign="top" style="text-align: center; background-position: center center !important; background-size: cover !important;"> <div> <table role="presentation" border="0" cellpadding="0" cellspacing="0" align="center" width="100%" style="max-width:500px; margin: auto;"> <tr> <td height="20" style="font-size:20px; line-height:20px;"> </td> </tr> <tr> <td align="center" valign="middle"> <table> <tr> <td valign="top" style="text-align: center; padding: 20px 0 10px 20px;"> <h1 style="margin: 0; font-family: Open Sans, sans-serif; font-size: 30px; line-height: 36px; color: #ffffff; font-weight: bold;">SİPARİŞİNİZ ALINDI</h1> </td> </tr> </table> </td> </tr> <tr> <td height="20" style="font-size:20px; line-height:20px;"> </td> </tr> </table> </div> </td> </tr> <tr> <td bgcolor="#ffffff"> <table role="presentation" cellspacing="0" cellpadding="0" border="0" width="100%"> <br><br> <tr> <td style="padding: 0px 40px 20px 40px; font-family: sans-serif; font-size: 15px; line-height: 20px; color: #555555; text-align: left; font-weight:normal;"> <p style="margin: 0;">Değerli kullanıcı, siparişiniz başarı ile alınmıştır. Bizi tercih ettiğiniz için teşekkür ederiz.</p> </td> </tr> <tr> <td style="padding: 0px 40px 20px 40px; font-family: sans-serif; font-size: 15px; line-height: 20px; color: #555555; text-align: left; font-weight:normal;"> <p style="margin: 0;">'. $degerler.' Toplam Tutar: '.$toplamtutar.' TL <br> Ödeme Yöntemi: '.$odememail.' </p> </td> </tr> <tr> <td style="padding: 0px 40px 20px 40px; font-family: sans-serif; font-size: 15px; line-height: 20px; color: #555555; text-align: left; font-weight:normal;"> <p style="margin: 0;">Güzel günler dileriz..</p> </td> </tr> </table> </td> </tr> <tr> <td bgcolor="#17A2B8"> <table role="presentation" cellspacing="0" cellpadding="0" border="0" width="100%"> <tr> <td style="padding: 40px 40px 5px 40px; text-align: center;"> <h1 style="margin: 0; font-family: Open Sans, sans-serif; font-size: 20px; line-height: 24px; color: #ffffff; font-weight: bold;">BİLGİLENDİRME</h1> </td> </tr> <tr> <td style="padding: 0px 40px 20px 40px; font-family: sans-serif; font-size: 17px; line-height: 23px; color: #aad4ea; text-align: center; font-weight:normal;"> <p style="margin: 0;">Değerli kullanıcı, bu işlemi siz yapmadıysanız eğer restaurant yetkilisini arıyarak bilgi isteyebilirsiniz.</p> </td> </tr> <tr> <td valign="middle" align="center" style="text-align: center; padding: 0px 20px 40px 20px;"> <table role="presentation" align="center" cellspacing="0" cellpadding="0" border="0" class="center-on-narrow"> <tr> <td style="border-radius: 50px; background: #ffffff; text-align: center;" class="button-td"> <a href="'.$ayar["web_adress"].'bize-ulasin" style="background: #ffffff; border: 15px solid #ffffff; font-family: Open Sans, sans-serif; font-size: 14px; line-height: 1.1; text-align: center; text-decoration: none; display: block; border-radius: 50px; font-weight: bold;" class="button-a"> <span style="color:#17A2B8;" class="button-link"> BİZE ULAŞIN </span> </a> </td> </tr> </table> </td> </tr> </table> </td> </tr> <tr> <td bgcolor="#ffffff"> <table role="presentation" cellspacing="0" cellpadding="0" border="0" width="100%"> <tr> <td style="padding: 40px 40px 10px 40px; font-family: sans-serif; font-size: 12px; line-height: 18px; color: #666666; text-align: center; font-weight:normal;"> <p style="margin: 0; font-weight: 700; font-size: 16px">Restaurant Bilgileri</p> </td> </tr> <tr> <td style="padding: 0px 40px 10px 40px; font-family: sans-serif; font-size: 12px; line-height: 18px; color: #666666; text-align: center; font-weight:normal;"> </td> </tr> <tr> <td style="padding: 0px 40px 10px 40px; font-family: sans-serif; font-size: 12px; line-height: 18px; color: #666666; text-align: center; font-weight:normal;"> <p style="margin: 0;"><a href="'.$ayar["web_adress"].'bize-ulasin" style="color: #111111; font-weight: 700;">İletişim Bilgileri</a> | <a href="'.$ayar["web_adress"].'menu" style="color: #111111; font-weight: 700;"> Menü</a> | <a href="'.$ayar["web_adress"].'siparis-durumu" style="color: #111111; font-weight: 700;"> Sipariş Takibi</a> | <a href="'.$ayar["web_adress"].'hesabim" style="color: #111111; font-weight: 700;"> Müşteri Paneli</a></p> </td> </tr> <tr> <td style="padding: 0px 40px 40px 40px; font-family: sans-serif; font-size: 12px; line-height: 18px; color: #666666; text-align: center; font-weight:normal;"> <p style="margin: 0;">'.$ayar["copyright"].'</p> </td> </tr> </table> </td> </tr> </table> </div> </center> </body> </html> '; $mail = new PHPMailer(true); try { $user= $smtp_settings->smtp_user; $mail->SMTPDebug = 0; $mail->isSMTP(); $mail->SMTPAuth = true; $mail->Username = $smtp_settings->smtp_user; $mail->Password = $smtp_settings->smtp_password; $mail->Host =$smtp_settings->smtp_server; $mail->Port = $smtp_settings->smtp_port; $mail->SMTPSecure = $smtp_settings->smtp_secure; $mail->SMTPOptions = array( 'ssl' => [ 'verify_peer' => false, 'verify_peer_name' => false, 'allow_self_signed' => true, ], ); $mail->SetLanguage('tr', 'PHPMailer/language/'); $mail->setFrom($user, 'Siparişiniz Alındı'); $mail->addAddress($_SESSION['mail']); $mail->isHTML(true); $mail->Subject = 'Siparişiniz Alındı'; $mail->Body = "$mailm "; $mail->CharSet = 'utf-8'; $mail->send(); //echo 'Mesaj gönderildi'; //header("location:".htmlspecialchars($_SERVER['HTTP_REFERER'])); } catch (Exception $e) { //echo 'Mesaj gönderilmedi. Hata: ', $mail->ErrorInfo; } }
💾 Kaydet
İptal
📝 Yeniden Adlandır
İptal
Kaydet
🔐 Dosya İzinleri (chmod)
İzin Değeri:
Hızlı Seçim:
777
755
644
600
777
= Herkes okur/yazar/çalıştırır
755
= Sahip tam, diğerleri okur/çalıştırır
644
= Sahip okur/yazar, diğerleri okur
600
= Sadece sahip okur/yazar
İptal
Uygula