protected function triggerError($msg, $no)
    {
        // determine previous stack frame
        $extra = '';
        if ($this->chatty) {
            $trace = debug_backtrace();
            // zip(tail(trace), trace) -- but PHP is not Haskell har har
            for ($i = 0, $c = count($trace); $i < $c - 1; $i++) {
                // XXX this is not correct on some versions of HTML Purifier
                if ($trace[$i + 1]['class'] === 'HTMLPurifier_Config') {
                    continue;
                }
                $frame = $trace[$i];
                $extra = " invoked on line {$frame['line']} in file {$frame['file']}";
                break;
            }
        }
        trigger_error($msg . $extra, $no);
    }
protected function triggerError($msg, $no)
    {
        // determine previous stack frame
        $extra = '';
        if ($this->chatty) {
            $trace = debug_backtrace();
            // zip(tail(trace), trace) -- but PHP is not Haskell har har
            for ($i = 0, $c = count($trace); $i < $c - 1; $i++) {
                // XXX this is not correct on some versions of HTML Purifier
                if ($trace[$i + 1]['class'] === 'HTMLPurifier_Config') {
                    continue;
                }
                $frame = $trace[$i];
                $extra = " invoked on line {$frame['line']} in file {$frame['file']}";
                break;
            }
        }
        trigger_error($msg . $extra, $no);
    }
protected function triggerError ( $ msg , $ no ) { // determine previous stack frame
 $ extra = '' ; if ( $ this -> chatty ) { $ trace = debug_backtrace ( ) ; // zip(tail(trace), trace) -- but PHP is not Haskell har har
 for ( $ i = 0 , $ c = count ( $ trace ) ; $ i < $ c - 1 ; $ i ++ ) { // XXX this is not correct on some versions of HTML Purifier
 if ( $ trace [ $ i + 1 ] [ 'class' ] === 'HTMLPurifier_Config' ) { continue ; } $ frame = $ trace [ $ i ] ; $ extra = " invoked on line {$frame['line']} in file {$frame['file']}" ; break ; } } trigger_error ( $ msg . $ extra , $ no ) ; }
Produces a nicely formatted error message by supplying the
stack frame information OUTSIDE of HTMLPurifier_Config.

@param string $msg An error message
@param int $no An error number
Produces a nicely formatted error message by supplying the stack frame information OUTSIDE of HTMLPurifier_Config .