]> sipb.mit.edu Git - ikiwiki.git/commitdiff
escape slashes in page names
authorjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Sun, 30 Jul 2006 21:51:37 +0000 (21:51 +0000)
committerjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Sun, 30 Jul 2006 21:51:37 +0000 (21:51 +0000)
IkiWiki/Plugin/aggregate.pm

index ba33a80aa23d06394ebb2e4d22b636b1412fcb3c..9c28651f03e06306e7d319fee2a448dc0b93731e 100644 (file)
@@ -252,7 +252,9 @@ sub add_page (@) { #{{{
                $feed->{newposts}++;
 
                # assign it an unused page
-               my $page=$feed->{dir}."/".IkiWiki::titlepage($params{title});
+               my $page=IkiWiki::titlepage($params{title});
+               $page=~s!([/])!"__".ord($1)."__"!eg; # escape slashes in title
+               $page=$feed->{dir}."/".$page;
                $page=lc($page);
                ($page)=$page=~/$IkiWiki::config{wiki_file_regexp}/;
                if (! defined $page || ! length $page) {