 |
|
Code (PHP)
if((move_uploaded_file($_FILES["filePO"]["tmp_name"],"myfile/".$_FILES["filePO"]["name"])&&(move_uploaded_file($_FILES["filePP"]["tmp_name"],"myfile/".$_FILES["filePP"]["name"]))))
{
$sql_in = " insert into datamain (job_no,supname , sup_tax, address, tel, email_sup , b_invoice , b_po , b_pp , invoice_no , po_no , pp_no , att_name , email_att , date_in , date_delivery, desciption , price_unit ,quantity, a_price , weight , packaging , total_price , total_weight ,active) values ('$job','$supname', '$suptax ', '$address', '$tel' ,'$email_sup', '".$_FILES["fileIN"]["name"]."' , '".$_FILES["filePO"]["name"]."' , '".$_FILES["filePP"]["name"]."', '$invoice' , '$po' , '$pp' ,'$att_n' , '$email_att' , NOW(), '$date_del', '$des', '$p_u','$qty', '$a_p', '$weight','$pack','$total_p','$total_w', 'wait') ";
$sql_q = mysql_query($sql_in);
$strTo = $_POST['email_att'];
$strSubject = "Activate Order";
$strHeader = "Content-type: text/html; charset=UTF-8\n";
$strHeader .= "From: [email protected]\nReply-To: [email protected]";
$strMessage = "";
$strMessage .= "Hello : ".$att_n."<br>";
$strMessage .= "=================================<br>";
$strMessage .= "Activate account click here.<br>";
$strMessage .= "http://www.e-localsystem.com";
$strMessage .= "=================================<br>";
$strMessage .= "ThaiCreate.Com<br>";
@mail($strTo,$strSubject,$strMessage,$strHeader);
echo "<script language=\"javascript\" type=\"text/javascript\"> alert('Complete') </script>";
echo "<meta http-equiv='refresh' content='0; url=vender.php'>" ;
}
ช่วยดูให้หน่อยครับ insert ข้อมูลลงนะครับ แต่ทำไม เมลล์ถึงไม่ไปครับ(พอดี copy ในบทความมาเลยยังไม่ได้แก้เท่าไรครับ) รบกวนช่วยดูให้หน่อยครับ
ปกติแล้ว โค้ดส่งเมลล์ จะทำการส่งเมลล์ ทันทีเลยไหมครับ หรือว่าขึ้นอยู่กับปัจจัยอื่นๆ
Tag : PHP, MySQL
|
|
 |
 |
 |
 |
Date :
2014-03-29 09:53:42 |
By :
Freeland |
View :
684 |
Reply :
4 |
|
 |
 |
 |
 |
|
|
|
 |