Newbie seeks urgent help

Thread Solved

Join Date: Apr 2007
Posts: 136
Reputation: dr4g is an unknown quantity at this point 
Solved Threads: 5
dr4g's Avatar
dr4g dr4g is offline Offline
Junior Poster

Re: Newbie seeks urgent help

 
0
  #11
Jul 24th, 2007
Originally Posted by Luc View Post
Taking the 'if' statement away from the mail functions worked :-)
The mail() function returns TRUE or FALSE upon sendin the email.
In order for you to write a decent script, you will have to verify that this mail was sent corrently.

Therefore you will need to wrap your mail() in an IF statement.
Otherwise your just firing an email out there and not getting any response back that it was successfull.

You can also do this to catch error messages instead of doing an if()

@mail(..);

The @ symbol would be an alternative to using the IF statement
GardCMS :: Open Source CMS :: Gardcms.org
Reply With Quote Quick reply to this message  
Join Date: Jul 2007
Posts: 11
Reputation: Luc is an unknown quantity at this point 
Solved Threads: 0
Luc Luc is offline Offline
Newbie Poster

Re: Newbie seeks urgent help

 
0
  #12
Jul 24th, 2007
Tnx for the reply but as i stated, everything works except for receiving the name of the contact in the body message of the e-mail.
Reply With Quote Quick reply to this message  
Join Date: Jul 2007
Posts: 11
Reputation: Luc is an unknown quantity at this point 
Solved Threads: 0
Luc Luc is offline Offline
Newbie Poster

Re: Newbie seeks urgent help

 
0
  #13
Jul 24th, 2007
Finally, it's solved:

I didn't define $contato_name.

So adding

  1.  
  2. $contato_name = $_POST['contato_name'];

did the trick :-)
Reply With Quote Quick reply to this message  
Join Date: Apr 2007
Posts: 136
Reputation: dr4g is an unknown quantity at this point 
Solved Threads: 5
dr4g's Avatar
dr4g dr4g is offline Offline
Junior Poster

Re: Newbie seeks urgent help

 
0
  #14
Jul 25th, 2007
Again, you need to validate your mail() command. By using @ or IF.
GardCMS :: Open Source CMS :: Gardcms.org
Reply With Quote Quick reply to this message  
Join Date: Jul 2007
Posts: 11
Reputation: Luc is an unknown quantity at this point 
Solved Threads: 0
Luc Luc is offline Offline
Newbie Poster

Re: Newbie seeks urgent help

 
0
  #15
Jul 25th, 2007
Done :-)
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:



Other Threads in the PHP Forum
Thread Tools Search this Thread



Tag cloud for PHP
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC