From: Daniel Friesen Date: Wed, 5 Jan 2011 06:16:13 +0000 (+0000) Subject: Allow filenames to be specified in a with the File:, Image: or media: omitt... X-Git-Tag: 1.31.0-rc.0~32813 X-Git-Url: https://git.cyclocoop.org/%20%27.%28%24debut%20%20%20%24par_page%29.%27?a=commitdiff_plain;h=7e0a31a4d4075728c21b3efc0509001b3fc2f608;p=lhc%2Fweb%2Fwiklou.git Allow filenames to be specified in a with the File:, Image: or media: omitted by defaulting to NS_FILE. --- diff --git a/includes/parser/Parser.php b/includes/parser/Parser.php index 3061a2d6f1..0ef79c9a4b 100644 --- a/includes/parser/Parser.php +++ b/includes/parser/Parser.php @@ -4526,7 +4526,7 @@ class Parser { if ( strpos( $matches[0], '%' ) !== false ) { $matches[1] = rawurldecode( $matches[1] ); } - $tp = Title::newFromText( $matches[1] ); + $tp = Title::newFromText( $matches[1], NS_FILE ); $nt =& $tp; if ( is_null( $nt ) ) { # Bogus title. Ignore these so we don't bomb out later.