diff options
author | Mike Macgirvin <mike@macgirvin.com> | 2010-10-26 22:09:13 -0700 |
---|---|---|
committer | Mike Macgirvin <mike@macgirvin.com> | 2010-10-26 22:09:13 -0700 |
commit | 2028e1695c82685102a7eef7f75094267446a887 (patch) | |
tree | 45101cd992941eaf90f3844b49e4cf90fbb8e599 /boot.php | |
parent | eb5e6aae7273fef06a06f983fe78aaad737aa729 (diff) | |
download | volse-hubzilla-2028e1695c82685102a7eef7f75094267446a887.tar.gz volse-hubzilla-2028e1695c82685102a7eef7f75094267446a887.tar.bz2 volse-hubzilla-2028e1695c82685102a7eef7f75094267446a887.zip |
rework the logging interface
Diffstat (limited to 'boot.php')
-rw-r--r-- | boot.php | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -1276,3 +1276,15 @@ function attribute_contains($attr,$s) { return false; }} +if(! function_exists('logger')) { +function logger($msg) { + + $debugging = get_config('system','debugging'); + $logfile = get_config('system','logfile'); + + if((! $debugging) || (! $logfile)) + return; + + @file_put_contents($logfile, datetime_convert() . ':' . session_id() . ' ' . $msg . "\n", FILE_APPEND); + return; +}} |