Commit 8fed0111 by sn

jetzt auch mit html output in extra Datei: http://host/mc_D_LOGFILE.log.html

1 parent 86d5667a
Showing with 25 additions and 2 deletions
......@@ -65,7 +65,7 @@ class D {
}
}
public static function printToScreen() {
public static function printToScreen($param_return=false) {
global $__mc_D_LOGFILE_ONLY_USER;
......@@ -78,10 +78,23 @@ class D {
// }
}
echo $screen_content;
if($param_return) {
return $screen_content;
} else {
echo $screen_content;
}
}
}
public static function printToHtmlFile($param_filename, $param_kindof = 'w') {
$screen_content = D::printToScreen(true);
mcFile::write($param_filename, $screen_content, $param_kindof);
}
public static function printPDOQuery($param_query, array $param_bindValueArray=null, $param_print=true, $param_force=false) {
// $return = '';
......
......@@ -15,6 +15,9 @@ if(!isset($_LOSP_DEV)) {
if($_LOSP_DEV) {
$__THIS_SCRIPT_INFO = pathinfo($_SERVER['SCRIPT_FILENAME']);
// echo $__THIS_SCRIPT_INFO['filename'];
if(!isset($__mc_D_LOGFILE_HTML)) {
$__mc_D_LOGFILE_HTML = $__mc_LOGDIR.'mcClasses.'.$__THIS_SCRIPT_INFO['filename'].'.'.$string.'.DEV_D.html';
}
}
/**
* @todo @since 20110325 die vars müssen eigentlich hier aus __mc raus ... da sie freeSN abhängig sind @author f@mensch.coop
......@@ -31,11 +34,14 @@ if(!isset($__mc_LOGDIR)) {
$__mc_LOGDIR = '';
}
if(!isset($__mc_D_LOGFILE)) {
/**
* @var string -- file for the D Output
*/
$__mc_D_LOGFILE = $__mc_LOGDIR.'mcClasses.'.$__THIS_SCRIPT_INFO['filename'].'.'.$string.'.DEV_D.log';
if(!isset($__mc_D_LOGFILE_RESET)) {
/**
......
......@@ -25,6 +25,10 @@ if($_LOSP_DEV) {
D::printToScreen();
}
if($__mc_D_LOGFILE_HTML) {
D::printToHtmlFile($__mc_D_LOGFILE_HTML);
}
if($__mc_D_LOGFILE) {
D::printToFile($__mc_D_LOGFILE,'a');
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!