diff --git a/syntax.php b/syntax.php index b53f20a..ec5ad0c 100644 --- a/syntax.php +++ b/syntax.php @@ -45,9 +45,17 @@ public function render($mode, Doku_Renderer $renderer, $data) { } # ODT Export Renderer elseif ($mode == 'odt'){ - $sapnote = explode('#', $data[0]); + if (!class_exists('ODTDocument')) { + // support of "old" dokuwiki-plugin-odt + $sapnote = explode('#', $data[0]); $renderer->doc .= "$sapnote[1]"; - return true; + return true; + } else { + // support of redesign dokuwiki-plugin-odt + $sapnote = explode('#', $data[0]); + $renderer->cdata ("$sapnote[1]"); + return true; + } } return false; }