diff options
Diffstat (limited to 'inc/parser/handler.php')
-rw-r--r-- | inc/parser/handler.php | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/inc/parser/handler.php b/inc/parser/handler.php index 0a021987f..9716bd74f 100644 --- a/inc/parser/handler.php +++ b/inc/parser/handler.php @@ -277,6 +277,18 @@ class Doku_Handler { return true; } + function phpblock($match, $state, $pos) { + global $conf; + if ( $state == DOKU_LEXER_UNMATCHED ) { + if ($conf['phpok']) { + $this->_addCall('phpblock',array($match), $pos); + } else { + $this->_addCall('file',array($match), $pos); + } + } + return true; + } + function html($match, $state, $pos) { global $conf; if ( $state == DOKU_LEXER_UNMATCHED ) { @@ -289,6 +301,18 @@ class Doku_Handler { return true; } + function htmlblock($match, $state, $pos) { + global $conf; + if ( $state == DOKU_LEXER_UNMATCHED ) { + if($conf['htmlok']){ + $this->_addCall('htmlblock',array($match), $pos); + } else { + $this->_addCall('file',array($match), $pos); + } + } + return true; + } + function preformatted($match, $state, $pos) { switch ( $state ) { case DOKU_LEXER_ENTER: @@ -1416,6 +1440,7 @@ class Doku_Handler_Block { 'quote_open', 'section_open', // Needed to prevent p_open between header and section_open 'code','file','hr','preformatted','rss', + 'htmlblock','phpblock', ); var $blockClose = array( @@ -1425,6 +1450,7 @@ class Doku_Handler_Block { 'quote_close', 'section_close', // Needed to prevent p_close after section_close 'code','file','hr','preformatted','rss', + 'htmlblock','phpblock', ); // Stacks can contain paragraphs |