Last modified: 2011-11-29 21:22:39 UTC
It seams that root urls and action paths can have a bit of a conflict: Under this setup: $wgArticlePath = "/$1"; $wgActionPaths['edit'] = "/edit/$1"; Our code inside WebRequest.php parses the article path first, as a result the edit url /edit/Foo is interpreted as the article [[Edit/Foo]]. We may want to re-order the way we parse paths inside WebRequest. Or perhaps we should replace the way we parse WebRequest sequentially with a system that will give more specific paths dominance. ie: If we have /* and /edit/* then /edit/* will win out over /* because it's more dominant. An unlikely circumstance like $wgActionPath = "/wiki/*" and $wgArticlePath['render'] = "/*"; would work if we went based on specificity instead of sequential parsing order.
"edit/Foo" is a legitimate page name (especially if $wgCapitalLinks is disabled)... this sort of thing is one of the reasons we recommend against putting your article and other spaces in the same place. :) But if folks do do this, swapping the order to recognize action paths first is probably better behavior for most cases.
Should be fixed by r104274.
As of r104385 action paths defined in $wgActionPaths are still being intercepted as article titles. Setting $wgActionPaths['edit'] = "/edit/$1": Page is treated as if the title is "Edit/$1", and displayed (though non-existent). Setting above plus $wgActionPaths['view'] = "/view/$1": Redirect loop to "/view/View/View/View/View/View/View/View/View/View/View/View/View/View/View/View/View/View/View/View/View/View/$1" I might not be setting the options correctly; my article-path-related LocalSettings.php code is below. Leaving as Resolved Fixed for now. ## The URL base path to the directory containing the wiki; ## defaults for all runtime URL paths are based off of this. ## For more information on customizing the URLs please see: ## http://www.mediawiki.org/wiki/Manual:Short_URL $wgScriptPath = ""; $wgScriptExtension = ".php"; $wgScript = "$wgScriptPath/index.php"; $wgArticlePath = "/$1"; # Action paths $actions = array( /*'view', causes redirect loop*/ 'edit', 'watch', 'unwatch', 'delete','revert', 'rollback', 'protect', 'unprotect', 'markpatrolled', 'render', 'submit', 'history', 'purge' ); foreach ( $actions as $action ) { $wgActionPaths[$action] = "/$action/$1"; } // $wgArticlePath = $wgActionPaths['view']; # causes redirect loop
r104274 is breaking all non-English languages and may need to be reverted.