config.php 4.46 KB
<?php
/** 
 * @copyright (c) 2014, netz.coop eG
 */
// $__PATH_to_mcClasses;


if(!isset($__BASEPATH_EX)) {
	$__BASEPATH_EX = '';
}

if(!isset($_LOSP_DEV)) {
	/**
	 * @var boolean -- activate the dev modus
	 */
	$_LOSP_DEV 		= 	true;
}
$__THIS_SCRIPT_INFO = pathinfo($_SERVER['SCRIPT_FILENAME']);
if($_LOSP_DEV) {
	
//	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';
	}
        if(!isset($__mc_D_LOGFILE_HTML_RESET)) {
		/**
		 * @var bool
		 *	remove every time the file and start a new file
		 *	@author f@mensch.coop @since 20120301
		 */
		$__mc_D_LOGFILE_HTML_RESET		=	false;
	}
}
/**
 * @todo @since 20110325 die vars müssen eigentlich hier aus __mc raus ... da sie freeSN abhängig sind @author f@mensch.coop
 */
if(isset($_TREE) && $_TREE) {
	$string = $_TREE;
} else if(isset($_PAGE_NAME) && $_PAGE_NAME) {
	$string = $_PAGE_NAME;
} else {
	$string = 'no';
}

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)) {
		/**
		 * @var bool
		 *	remove every time the file and start a new file
		 *	@author f@mensch.coop @since 20120301
		 */
		$__mc_D_LOGFILE_RESET		=	true;
	}
	
	if(!isset($__mc_D_LOGFILE_ONLY_USER)) {
		$__mc_D_LOGFILE_ONLY_USER = true;
	}
}

if(!isset($__mc_D_SCREENOUTPUT)) {
	/**
	 * @var boolean -- activate the D Output on screen
	 */
	$__mc_D_SCREENOUTPUT 	= 	false;
}


if(!isset($__mc_INPUT_LOGFILE)) {
	/**
	 * @var string -- file for the D Output
	 */
	$__mc_INPUT_LOGFILE 		= 	$__mc_LOGDIR.'mcClasses.'.$__THIS_SCRIPT_INFO['filename'].'.'.$string.'.DEV_INPUT.log';
	
	if(!isset($__mc_INPUT_LOGFILE_RESET)) {
		/**
		 * @var bool
		 *	remove every time the file and start a new file
		 *	@author f@mensch.coop @since 20120301
		 */
		$__mc_INPUT_LOGFILE_RESET		=	true;
	}	
}

if(!isset($__mc_PDO_LOGFILE)) {
	/**
	 * @var string -- file for the D Output
	 */
	$__mc_PDO_LOGFILE 		= 	$__mc_LOGDIR.'mcClasses.'.$__THIS_SCRIPT_INFO['filename'].'.'.$string.'.DEV_PDO.sql';
	
	if(!isset($__mc_PDO_LOGFILE_RESET)) {
		/**
		 * @var bool
		 *	remove every time the file and start a new file
		 *	@author f@mensch.coop @since 20120301
		 */
		$__mc_PDO_LOGFILE_RESET		=	true;
	}	
}





if(!isset($__mcPerformance_backtrace)) {
	/**
	 * @var boolean -- activate the D Output on screen
	 */
	$__mcPerformance_backtrace 	= 	true;
}

if(!isset($__mc_ERRORHANDLER)) {
	/**
	 * @var boolean -- is true use the mcErrorHandler
	 */
	$__mc_ERRORHANDLER = true;
}

if(!isset($__mc_DEPRECATED)) {
	/**
	* @var int
	 * if you want @deprecated functions since a date (format: yyyymmdd)
	 */
	$__mc_DEPRECATED = 20110201;
}


if(!isset($__mc_Report)) {
	/**
	 * @var array -- configuration of the report (mcNoticeEvent, mcErrorEvent, Error)
	 */
	$__mc_Report = array(
		'mcNoticeEvent' => array(
			'toScreen' => array(),
			'toFile' => array('file' => $__mc_LOGDIR.'mcClasses_NoticeEvent.'.$__THIS_SCRIPT_INFO['filename'].'.log')
		),
		'mcErrorEvent' => array(
			'toScreen' => array(),
			'toFile' => array(
					'file' => $__mc_LOGDIR.'mcClasses_ErrorEvent.'.$__THIS_SCRIPT_INFO['filename'].'.log',
					'writemode' => 'a',
					'reset' => false,
			),
//			'toMail' => array(
//				'mail' => 'mail@localhost.tld',
//				'subject' => 'Error:'
//			)
		),
		'mcXSLErrorEvent' => array(
			'toScreen' => array(),
			'toFile' => array(
					'file' => $__mc_LOGDIR.'mcClasses_XSLErrorEvent.'.$__THIS_SCRIPT_INFO['filename'].'.log',
					'writemode' => 'a',
					'reset' => false,
			),
//			'toMail' => array(
//				'mail' => 'mail@localhost.tld',
//				'subject' => 'Error:'
//			)
		),		
		'mcException' => array(
			'toScreen' => array(),
			'toFile' => array(
					'file' => $__mc_LOGDIR.'mcClasses_Exception.'.$__THIS_SCRIPT_INFO['filename'].'.log',
					'writemode' => 'a',
					'reset' => false,
			),
//			'toMail' => array(
//				'mail' => 'mail@localhost.tld',
//				'subject' => 'Error:'
//			)
		),
		'Error' => array(
			'toScreen' => array('text' => 'ERROR Error ERROR Error ERROR'),
			'toFile' => array(
					'file' => $__mc_LOGDIR.'mcClasses_Error.'.$__THIS_SCRIPT_INFO['filename'].'.config.log',
					'writemode' => 'a',
					'reset' => false,
			),
//			'toMail' => array(
//				'mail' => 'mail@localhost.tld',
//				'subject' => 'Error:'
//			)
		),
	);
}
?>