*/ // must be run within DokuWiki if(!defined('DOKU_INC')) die(); if(!defined('DOKU_PLUGIN')) define('DOKU_PLUGIN',DOKU_INC.'lib/plugins/'); require_once DOKU_PLUGIN.'syntax.php'; /** * All DokuWiki plugins to extend the parser/rendering mechanism * need to inherit from this class */ class syntax_plugin_bez_nav extends DokuWiki_Syntax_Plugin { function getPType() { return 'block'; } function getType() { return 'substition'; } function getSort() { return 99; } function connectTo($mode) { $this->Lexer->addSpecialPattern('~~BEZNAV~~',$mode,'plugin_bez_nav'); } function handle($match, $state, $pos, &$handler) { return true; } function render($mode, &$renderer, $data) { $helper = $this->loadHelper('bez'); if ($mode == 'xhtml' && $helper->user_viewer()) { $renderer->doc .= ''; return true; } else $renderer->meta['plugin_bez_nav']['nocache'] = true; return false; } }