the mail() again!!!!

From: Date: Thu, 15 Mar 2001 18:58:50 +0000
Subject: the mail() again!!!!
Groups: php.general 
Request: Send a blank email to php-general+get-44216@lists.php.net to get a copy of this message
Hi I have installed php4 with apache onto my windows 98 machine .I am trying to send an email using the mail() function . When i run the following piece of code i get a warning .Can anyone please help me figure what has gone wrong and suggest me with what to do. **************************** This is the code!! <?php $mailto = "nilesh_parmar@rediff.com; $mailsub = "this is a php mail() function"; $body = " i hope this works"; if (mail($mailto ,$mailsub, $body)) echo("successfully sent an email to $mailto"); else echo("failed to send the email \"$mailsub\" to $mailto"); ?> ************************************* the following is the warining i get. Warning: Server Error in c:\program files\apache group\apache\htdocs\nilesh\mail.php on line 6 failed to send the email "this is a php mail() function" to nilesh_parmar@rediff.com ******************************************** Hoping someone can help me in this regard bye and thanx in advance Nilesh Parmar

« previous php.general (#44216) next »