private static function _log($msgType, $args)
    {
        if (!Config::getField('project', 'debug_mode', 0)) {
            return;
        }

        if (count($args) == 1) {
            $msg = is_scalar($args[0]) ? $args[0] : self::dump($args[0]);
        } else {
            $msg = self::dump($args);
        }

        if (self::$DEBUG_TRACE) {
            $trace = self::getTrace();
        } else {
            $trace = array();
        }
        if ($msgType == 'debug') {
            Terminal::drawStr($msg, 'magenta');
        } else if ($msgType == 'error') {
            Terminal::drawStr($msg, 'red');
        } else if ($msgType == 'info') {
            Terminal::drawStr($msg, 'brown');
        } else {
            Terminal::drawStr($msg, 'default');
        }
        //echo "\n";
        !empty($trace) && Terminal::drawStr("\t" . implode(" <-- ", $trace) . "\n");
    }
private static function _log($msgType, $args)
    {
        if (!Config::getField('project', 'debug_mode', 0)) {
            return;
        }

        if (count($args) == 1) {
            $msg = is_scalar($args[0]) ? $args[0] : self::dump($args[0]);
        } else {
            $msg = self::dump($args);
        }

        if (self::$DEBUG_TRACE) {
            $trace = self::getTrace();
        } else {
            $trace = array();
        }
        if ($msgType == 'debug') {
            Terminal::drawStr($msg, 'magenta');
        } else if ($msgType == 'error') {
            Terminal::drawStr($msg, 'red');
        } else if ($msgType == 'info') {
            Terminal::drawStr($msg, 'brown');
        } else {
            Terminal::drawStr($msg, 'default');
        }
        //echo "\n";
        !empty($trace) && Terminal::drawStr("\t" . implode(" <-- ", $trace) . "\n");
    }
private static function _log ( $ msgType , $ args ) { if ( ! Config :: getField ( 'project' , 'debug_mode' , 0 ) ) { return ; } if ( count ( $ args ) == 1 ) { $ msg = is_scalar ( $ args [ 0 ] ) ? $ args [ 0 ] : self :: dump ( $ args [ 0 ] ) ; } else { $ msg = self :: dump ( $ args ) ; } if ( self :: $ DEBUG_TRACE ) { $ trace = self :: getTrace ( ) ; } else { $ trace = array ( ) ; } if ( $ msgType == 'debug' ) { Terminal :: drawStr ( $ msg , 'magenta' ) ; } else if ( $ msgType == 'error' ) { Terminal :: drawStr ( $ msg , 'red' ) ; } else if ( $ msgType == 'info' ) { Terminal :: drawStr ( $ msg , 'brown' ) ; } else { Terminal :: drawStr ( $ msg , 'default' ) ; } //echo "\n"; ! empty ( $ trace ) && Terminal :: drawStr ( "\t" . implode ( " <-- " , $ trace ) . "\n" ) ; }
Send print to terminal.
Send print to terminal .