note 51136 added to function.mail

From: Date: Mon, 21 Mar 2005 12:35:27 +0000
Subject: note 51136 added to function.mail
Groups: php.notes 
Request: Send a blank email to php-notes+get-86740@lists.php.net to get a copy of this message
<?PHP $feedname=$HTTP_POST_VARS['feedname']; $feedmail=$HTTP_POST_VARS['feedmail']; $feedback=$HTTP_POST_VARS['feedback']; $toaddress="milenzlatkov@yahoo.com"; $subject="Feedback from Milen web site :)"; /*$mailcontent='Customer name: '.$feedname."\n" .'Customer e-mail: '.$feedmail."\n" ."Customer Comments: \n".$feedback."\n";*/ $mailcontent="Line 1\nLine 2\nLine 3"; $fromaddress='From: webserver@example.com'; //mail($toaddress,$subject,$mailcontent); //mail('milenzlatkov@yahoo.com','Feedback','Line 1\nLine 2\nLine 3'); if (mail($toaddress,$subject,$mailcontent)) { echo 'Success'; } else { echo 'Failed'; } ?> RESULT: Content-type: text/html X-Powered-By: PHP/4.3.6 <br /> <b>Warning</b>: mail(): &quot;sendmail_from&quot; not set in php.ini or custom &quot;From:&quot; header missing in <b>D:\Program Files\Apache Group\Apache\htdocs\chapter04\ProcessFeedbackz.php</b> on line <b>16</b><br /> Failed ..............this above is reprted from Zend Sudio Environment /I have not Zend Studio Server/, but through http://localhost/chapter04/PHPDocument3.php my browser /Opera 7.5x/ shows 'Success'. In my Yahoo account is not received any e-mail indicating in function MAIL(.....) I don't understand where's the mistake :()~ .....help me ---- Manual Page -- http://www.php.net/manual/en/function.mail.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+51136 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+51136&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+51136&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+51136&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+51136&report=yes&reason=useless Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+51136&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+51136&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#86740) next »