Jump to content



Latest News: (loading..)

- - - - -

[PHP 5.4.3] Import method failed in ErrorHandler.class

errorlog module php 5.4

  • Please log in to reply
No replies to this topic

#1   foxp2

foxp2

    strong as a Twig

  • Members
  • 303 posts
  • Real Name:Laurent
  • Gender:Male
  • Location:France

Posted 16 August 2012 - 03:31 PM

Hi,
with php 5.4.x, errors are written with this format (in errors.txt) :

Quote

[16-Aug-2012 14:41:35 UTC] PHP Parse error: ..../....

my patch for preg_match function's:

		if ( preg_match('/^\[([0-9]{2})-([A-Za-z]{3})-([0-9]{4}) ([0-9]{2}):([0-5][0-9]):([0-5][0-9]) ' . ini_get('date.timezone') .'\] (.*)$/', $error) ) {
		  $timestamp = DateTime::getTimestamp(substr($error, 1, 20), 'd-M-Y H:i:s');
		  $message = substr($error, 23 + strlen(ini_get('date.timezone')));

-------------------