0

Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\wamp\www\baby\mail_result.php on line 16

<?php
$contact_us=1;
include("dbconnect.php");
include("funksione.php");
include("header.php");
include("left.php");
include("tbl_begin.php");
$from=$_POST['email'];
$sender=$_POST['name'];
$headers = 'From: $sender' . "\r\n" .
    'Reply-To: $from' . "\r\n" .
    'X-Mailer: PHP/' . phpversion();			
$to = "a.fejza@hotmail.om";
$subject = "Hi!";
$body = $_POST['enquiry'];
if (mail($to, $subject, $body, $headers))
 {
  echo("<p>Message successfully sent!</p>");
 } else {
  echo("<p>Message delivery failed...</p>");
 }
include("tbl_end.php");
include("footer.php");
?>
2
Contributors
1
Reply
2
Views
6 Years
Discussion Span
Last Post by pritaeas
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.