Avoid spurious paragraph with new heading id's
authorAryeh Gregor <simetrical@users.mediawiki.org>
Tue, 17 Aug 2010 21:55:21 +0000 (21:55 +0000)
committerAryeh Gregor <simetrical@users.mediawiki.org>
Tue, 17 Aug 2010 21:55:21 +0000 (21:55 +0000)
Bug 24835.  The use of <a> made the parser put <p> around the tag, so
use <div> instead.  (Something was also adding a name="" attribute, but
I'm not sure what.  That should be killed.)

includes/Linker.php

index 64fb366..af8332a 100644 (file)
@@ -1439,7 +1439,7 @@ class Linker {
                        . " <span class=\"mw-headline\" id=\"$anchor\">$text</span>"
                        . "</h$level>";
                if ( $legacyAnchor !== false ) {
-                       $ret = "<a id=\"$legacyAnchor\"></a>$ret";
+                       $ret = "<div id=\"$legacyAnchor\"></div>$ret";
                }
                return $ret;
        }