From 3e55d035ce3b611d07546b63ea8bf6315a43e617 Mon Sep 17 00:00:00 2001
From: Andreas Gohr <andi@splitbrain.org>
Date: Sat, 11 Mar 2006 21:10:15 +0100
Subject: [PATCH] empty paragraph fixup for XHTML renderer

as discussed on the mailinglist

darcs-hash:20060311201015-7ad00-2eef847a38e711411be8fbac41c5a2cc7328886f.gz
---
 inc/parser/xhtml.php | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/inc/parser/xhtml.php b/inc/parser/xhtml.php
index bb7adf1da..2335c8b65 100644
--- a/inc/parser/xhtml.php
+++ b/inc/parser/xhtml.php
@@ -93,6 +93,9 @@ class Doku_Renderer_xhtml extends Doku_Renderer {
         if($this->info['toc']){
             $this->doc = $this->render_TOC().$this->doc;
         }
+
+        // make sure there are no empty paragraphs
+        $this->doc = preg_replace('#<p(>| .*?>)\s*</p>#','',$this->doc);
     }
 
     /**
-- 
GitLab