Last modified: 2007-06-13 19:23:47 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T12243, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 10243 - Fails to extract proper page information with modified $wgArticlePath
Fails to extract proper page information with modified $wgArticlePath
Status: RESOLVED INVALID
Product: MediaWiki
Classification: Unclassified
API (Other open bugs)
1.11.x
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-06-13 16:58 UTC by Tikhon Botchkarev
Modified: 2007-06-13 19:23 UTC (History)
0 users

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


Attachments
Patch for WebRequest::interpolateTitle() to process $wgScript before $wgArticlePath (511 bytes, patch)
2007-06-13 18:26 UTC, Tikhon Botchkarev
Details

Description Tikhon Botchkarev 2007-06-13 16:58:44 UTC
Wiki installation is located in /wiki, RewriteRules were disabled for this example. When using a custom $wgArticlePath such as:

$wgArticlePath = "/wiki/$1";

Any access to the wiki though the actual entry point script such as:

GET /wiki/index.php?title=Main_Page&action=edit

or

GET /wiki/index.php?title=Main_Page&action=history

Will result in the parser attempting to operate on the [[Index.php]] page instead of the page in title.
Comment 1 Tikhon Botchkarev 2007-06-13 18:26:17 UTC
Created attachment 3757 [details]
Patch for WebRequest::interpolateTitle() to process $wgScript before $wgArticlePath

Added patch that fixes above problem. The problem originated in WebRequest::interpolateTitle(). That function tries to figure out the title of the requested page based on the $wgArticlePath. If the path is set to allow Rewrite Conditions the action pages are still requested in the /index.php?actions format, which leads to the WebRequest::extractTitle() function to return index.php.
Comment 2 Brion Vibber 2007-06-13 19:02:28 UTC
This appears to be correct behavior per spec; /wiki/index.php?title=Main_Page&action=edit would indeed refer to a page "index.php" with additional parameters tacked on.

Your URL scheme overlaps two separate areas (the files & scripts area and the wiki-page-space area), and one's going to win out.

I would recommend fixing your URL scheme.
Comment 3 Tikhon Botchkarev 2007-06-13 19:23:47 UTC
Upon looking at it a bit more I can see what you meant and have fixed my mistake. It may be worth it to either reconsider this behaviour or do some extra documentation or checking, as a lot of examples online provided this type of configuration and it did not yield any problems in older releases.

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


Navigation
Links