Last modified: 2011-03-13 18:04:30 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 11314 - Spaces in mediawiki name causes infinite redirect loop
Spaces in mediawiki name causes infinite redirect loop
Product: MediaWiki
Classification: Unclassified
Redirects (Other open bugs)
All All
: Lowest major (vote)
: ---
Assigned To: Nobody - You can work on this!
Depends on: 10787
  Show dependency treegraph
Reported: 2007-09-12 20:44 UTC by Ziba Scott
Modified: 2011-03-13 18:04 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Description Ziba Scott 2007-09-12 20:44:58 UTC
The new WebRequest::interpolateTitle method in 1.11 passes at least 2 arguments to WebRequest::extractTitle:

$path and $wgArticlePath

$path is urlencoded, $wgArticlePath is not.

WebRequest:extractTitle does a substring comparison on the two arguments.  This works fine if there were no urlencoded characters in $path.  But as soon as $path has a %20 or the like, WebRequest:extractTitle returns false, so WebRequest::interpolateTitle doesn't populate $_GET, so mediawiki redirects over and over trying to populate $_GET.

For my uses and simple testing so far, this solution seems to have worked:

In includes/WebRequest.php on line 53 change:
                    $path = $a['path'];
                    $path = urldecode($a['path']);

Thank you for your time in looking at this.
Comment 1 Brion Vibber 2008-02-12 22:51:55 UTC
$wgArticlePath *should* be properly URL-encoded, as it's used to construct URLs.

The installer may not be putting together a proper default $wgScriptPath, however... Linking this bug to bug 10787, which has some further discussion on the matter.
Comment 2 Aaron Schulz 2008-09-12 22:43:48 UTC
$wgArticlePath should already be encoded, rather than having the code waste the time encoding it.

Note You need to log in before you can comment on or make changes to this bug.