Jump to content

[SOLVED] CRON JOB Email contenet


Voodoo Jai

Recommended Posts

I now have my CRON JOB running a treat thanks to all the help from the PHPFreaks, but now I am wondering how to chang ethe blank email into something readable.

Your CRON JOB was successful and the changes have been made. Blah blah blah"

 

Do I just echo some statements, in the php file that is executed.

 

echo "Blah blah blah . . . . . ";

 

Thanks again

 

VoodooJai

Link to comment
https://forums.phpfreaks.com/topic/114268-solved-cron-job-email-contenet/
Share on other sites

not exactly sure what you are asking.  Is your script currently just sending a blank email and you want it to actually send some info?

 

the syntax for mail() is mail($to, $subject, $message, $headers);

 

so in your script you just need to create a string containing the info you want to email and then pass it to mail() as the 3rd argument.

 

everything echo'd (to stdout) in a cron run script will be written to syslog unless you redirect it.  So echoing output in a cron script is only really good for debugging and logging.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.