(bug 11659) Urldecode image names in galleries (fixed in a similar way as done for...
authorBryan Tong Minh <btongminh@users.mediawiki.org>
Sun, 1 Jun 2008 18:31:40 +0000 (18:31 +0000)
committerBryan Tong Minh <btongminh@users.mediawiki.org>
Sun, 1 Jun 2008 18:31:40 +0000 (18:31 +0000)
RELEASE-NOTES
includes/Parser.php

index 211b78b..67e3b2b 100644 (file)
@@ -318,6 +318,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
 * (bug 14370) When a grouppage-x message does not exist the entry on the
   ListGroupRights special page links to the main namespace page not the project
   namespace page.
+* (bug 11659) Urldecode image names in galleries
 
 === API changes in 1.13 ===
 
index 0b8497f..a763ab1 100644 (file)
@@ -4366,6 +4366,9 @@ class Parser
                        if ( count( $matches ) == 0 ) {
                                continue;
                        }
+                       
+                       if ( strpos( $matches[0], '%' ) !== false )
+                               $matches[1] = urldecode( $matches[1] );
                        $tp = Title::newFromText( $matches[1] );
                        $nt =& $tp;
                        if( is_null( $nt ) ) {