Wink Saville’s Blog

February 22, 2008

Firefox/Apache - debug server side php code

Filed under: Apache, firefox — wink @ 11:10 am

To apache debug server-side scripts the typical solution is to usr print statements back to the browser. But that won’t work for AJAX as there isn’t any place to view the output.

The other method is to log to a file

$fp = fopen(’debug.php’, ‘ab’);
fwrite($fp, “debug data …”);
// Then eventually close
fclose($fp);

Powered by WordPress