email - my code doesn't work (php) -


this question has answer here:

my code save info in database doesn't send message email , alert message not work. can me , please ?

`

if(isset($_post['send'])){     $to = "nada_26_@hotmail.com"; // email address     $subject = "form contact";     $subject2 = "copy of form submission";     $name = $_post['name'];     $from = $_post['email'];     $subject3 = $_post['subject'];     $company = $_post['company'];     $content = $_post['message'];     $message = "name: ".$name ." subject: " . $subject3 . " company: " . $company ."\n\n".$content;     $message2 = "here copy of message " . "\n\n" . $_post['message'];      $headers = "from:" . $from;     $headers2 = "from:" . $to;     mail($to,$subject,$message,$headers); //send message admin     mail($from,$subject2,$message2,$headers2); // sends copy of message sender       $sql ="insert threadnn_arab.contactus values('$name','$from','$subject3','$company','$message','')";     $result=mysql_query($sql);               echo "<script> alert('mail sent, thank you, contact shortly.'); </script>";                     header('location: index.php?#contact');                            } ?>  ` 

i think on email provider, smtp may be.or can using phpmailer in question send email hotmail using php


Comments

Popular posts from this blog

magento2 - Magento 2 admin grid add filter to collection -

Android volley - avoid multiple requests of the same kind to the server? -

Combining PHP Registration and Login into one class with multiple functions in one PHP file -