Re: Problem with mail()

From: Date: Thu, 17 Jun 2004 20:04:37 +0000
Subject: Re: Problem with mail()
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-188510@lists.php.net to get a copy of this message
This should work: if (mail($to, $subj, $bodytext)) { echo "Mail send"; } else { echo "... something go wrong: } One tip: when configuring/installing php, if there is not /usr/bin/sendmail it asumes that there is no way of send mails so mail function always return false, check that just in case. > So what do you get as the error message? Does it just return failed? > Also, I think using parentheses with echo statements like yours is > unnecessary. > >> Keith Aldridge wrote: >> New to php, can't see the problem with mail(). > >> > > -- > Ashwin Purohit > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > >

« previous php.general (#188510) next »