biba028 Posted December 14, 2009 Share Posted December 14, 2009 I have php codes running under a cron job. But everytime i output (echo) , it comes out as complete text: THe php script is setup to output some stuff so they are sent to the cron email... but all the html tags shows up in the email too! example: Hello<br />World instead of Hello World even when i put html codes, i see the html tags literally. Link to comment https://forums.phpfreaks.com/topic/185037-cron-job-and-output/ Share on other sites More sharing options...
trq Posted December 14, 2009 Share Posted December 14, 2009 Emails are generally meant to be sent in plain text. I'm not sure where exactly you would configure your systems mail program to send as html, but your question has nothing at all to do with php. Link to comment https://forums.phpfreaks.com/topic/185037-cron-job-and-output/#findComment-976729 Share on other sites More sharing options...
biba028 Posted December 14, 2009 Author Share Posted December 14, 2009 my code is in php here is the cron job : /usr/bin/GET http://path_to_my_php Link to comment https://forums.phpfreaks.com/topic/185037-cron-job-and-output/#findComment-976731 Share on other sites More sharing options...
trq Posted December 14, 2009 Share Posted December 14, 2009 my code is in php here is the cron job : /usr/bin/GET http://path_to_my_php Your script might be written in php, but the email (generated via cron) is sent via your systems default MTA. Link to comment https://forums.phpfreaks.com/topic/185037-cron-job-and-output/#findComment-976733 Share on other sites More sharing options...
biba028 Posted December 14, 2009 Author Share Posted December 14, 2009 thanks. do you have any suggestions ? should i use php -q file.php instead of GET http://phppath ? Link to comment https://forums.phpfreaks.com/topic/185037-cron-job-and-output/#findComment-976734 Share on other sites More sharing options...
trq Posted December 14, 2009 Share Posted December 14, 2009 thanks. do you have any suggestions ? should i use php -q file.php instead of GET http://phppath ? Why would that make a difference? As I said, the email isn't being sent by your php script. Link to comment https://forums.phpfreaks.com/topic/185037-cron-job-and-output/#findComment-976737 Share on other sites More sharing options...
biba028 Posted December 14, 2009 Author Share Posted December 14, 2009 thanks i got it now Link to comment https://forums.phpfreaks.com/topic/185037-cron-job-and-output/#findComment-976739 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.