* (bug 2374) Allow extension tags to be terminated empty elements
[lhc/web/wiklou.git] / includes / Parser.php
index 1167711..a910afe 100644 (file)
@@ -272,6 +272,9 @@ class Parser
                        $params = array( );
                }
 
+               // Hack to support short XML style tags
+               $text = preg_replace( "/<$tag(\\s+[^>]*|\\s*)\\/>/i", "<$tag\\1></$tag>", $text );
+               
                if( $tag == STRIP_COMMENTS ) {
                        $start = '/<!--()/';
                        $end   = '/-->/';