just make sure its executing the if like
PHP Code:
if($n == 1){ echo 'Hello World'; // you code }
if it does, then the problem would be in your mail sending code.
From where you are trying run the code, ie from your local or server,
if from local, then have you configured the SMTP host and port properly?
if from server, then check the mail sending functionality by a test page and see whether the mails are sent from your server..
__________________
There is no secret ingredient.
|