bludit/bl-kernel/helpers/log.class.php
2018-07-28 18:33:37 +02:00

25 lines
608 B
PHP

<?php defined('BLUDIT') or die('Bludit CMS.');
class Log {
public static function set($text, $type=LOG_TYPE_INFO)
{
if (!DEBUG_MODE) {
return false;
}
$messageType = 0;
if (is_array($text) ) {
error_log('------------------------', $messageType);
error_log('Array', $messageType);
error_log('------------------------', $messageType);
foreach ($text as $key=>$value) {
error_log($key.'=>'.$value, $messageType);
}
error_log('------------------------', $messageType);
}
error_log($type.' ['.BLUDIT_VERSION.'] ['.$_SERVER['REQUEST_URI'].'] '.$text, $messageType);
}
}