Send errors message via email using error_log()

georbGele

New Member
The php function error_log() let you send logs to email setting the second param to 1. I do that, but i want to dispay message in html. The code looks like this:\[code\]error_log($this->_errorMsg, 1, ADMIN_MAIL, "Content-Type: text/html; charset=utf8\r\nFrom: ".MAIL_ERR_FROM."\r\nTo: ".ADMIN_MAIL);\[/code\]Probably i mess something declaring the content type, because i get msg in plain text:\[code\]<h1>Website Error</h1><b>ERRNO:</b><font color='red'>1</font>...\[/code\]
 
Back
Top