Mercurial > hg > ywww
view dlog.php @ 57:7f90ac957713
necessary when included inside a function
author | Charlie Root |
---|---|
date | Sun, 09 Jun 2019 06:47:19 -0400 |
parents | dbc006408d2b |
children |
line wrap: on
line source
<?php global $logfile; if (isset($_SERVER['DOCUMENT_ROOT'])) { $logfile=$_SERVER['DOCUMENT_ROOT']."/debug/debug.log"; } else { $logfile="/tmp/php_debug.log"; } function dl($s) { global $logfile; file_put_contents($logfile,$s,FILE_APPEND); }