From f6e436bb1c5f6875923c9350eaaf9f877d05b5a2 Mon Sep 17 00:00:00 2001 From: Igor Date: Sun, 31 Oct 2010 20:23:13 +0300 Subject: Valid XHTML --- README | 9 +++++++++ syntax.php | 11 +++++++---- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/README b/README index f39bca5..fc07870 100644 --- a/README +++ b/README @@ -11,9 +11,18 @@ It introduces two syntax extentions for Dokuwiki: Raw BiBTeX data +1.1 Notes + +For final output to be valid XHTML +no empty line are allowed before + + + 2. Publications selected from by some attributes. +(Not implemented yet) + author = pashev, year = 2005 diff --git a/syntax.php b/syntax.php index a2a80e1..3240b0c 100644 --- a/syntax.php +++ b/syntax.php @@ -26,7 +26,7 @@ class syntax_plugin_papers extends DokuWiki_Syntax_Plugin { function getType() { return 'protected'; } - function getPType() { return 'stack'; } + function getPType() { return 'block'; } // http://www.dokuwiki.org/devel:syntax_plugins#ptype function getSort() { return 102; } @@ -113,7 +113,9 @@ class syntax_plugin_papers extends DokuWiki_Syntax_Plugin $year_prev = $year; $type_prev = ''; - $res .= $this->wikirender('===== ' . $year . ' ' . $this->getLang('year') . ' ====='); + //$res .= $this->wikirender('===== ' . $year . ' ' . $this->getLang('year') . ' ====='); + $res .= "

$year " + . $this->getLang('year') . "

\n"; } $type = $entry['entry']; @@ -121,12 +123,13 @@ class syntax_plugin_papers extends DokuWiki_Syntax_Plugin { if ($in_list) { - $res .= "\n"; + $res .= "\n\n\n"; $in_list = false; } $type_prev = $type; - $res .= $this->wikirender('==== ' . $this->getLang($type) . ' ===='); + //$res .= $this->wikirender('==== ' . $this->getLang($type) . ' ===='); + $res .= '

' . $this->getLang($type) . "

\n"; } if (!$in_list) -- cgit v1.2.3