]> sipb.mit.edu Git - ikiwiki.git/blobdiff - IkiWiki/Plugin/toc.pm
web commit by PatrickWinnertz
[ikiwiki.git] / IkiWiki / Plugin / toc.pm
index 279eef00837a66c901056096c89af1c1180e6a42..bc62f71d6858cb302ef23549e5f63fe9152957e9 100644 (file)
@@ -4,7 +4,7 @@ package IkiWiki::Plugin::toc;
 
 use warnings;
 use strict;
-use IkiWiki;
+use IkiWiki 2.00;
 use HTML::Parser;
 
 sub import { #{{{
@@ -47,7 +47,7 @@ sub format (@) { #{{{
                if ($tagname =~ /^h(\d+)$/i) {
                        my $level=$1;
                        my $anchor="index".++$anchors{$level}."h$level";
-                       $page.="$text<a name=\"$anchor\" />";
+                       $page.="$text<a name=\"$anchor\"></a>";
        
                        # Take the first header level seen as the topmost level,
                        # even if there are higher levels seen later on.