PHPform to actually send an email and then depending on whether email is sent or not the Processor.php is displayed

Hi again
I have a form with action processor.php. and containg multiple selects.
Processor.php just refines the form and says "Thank you,you have ordered so many $bulbs of $bname"
What i need is to use the form to actually send an email and then depending on whether email is sent or not the Processor.php is displayed. Just something simple.
Much appreciated in advance.
Leighjor
LeighJorAsked:
Who is Participating?
 
Michael701Connect With a Mentor Commented:
well mail returns a boolean

$mail_sent=mail("joecool@example.com", "My Subject", "Line 1\nLine 2\nLine 3");
if ($mail_sent)
{
  echo "email has been sent";
}
0
 
LeighJorAuthor Commented:
so simple: both the answer and moi ;-)
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.