https://bugzilla.wikimedia.org/show_bug.cgi?id=8130
[email protected] changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #2 from [email protected] 2009-03-11 21:53:24 UTC --- This bug has been a problem on the wiki where I'm an admin (www.uesp.net), because our site makes extensive use of content namespaces other than NS_MAIN. I've implemented a code modification on our wiki that fixes this bug, and I think it would be useful if the same fixes could be implemented in the core mediawiki code. In my previous comment I uploaded a patch file that implements all of the suggested changes. I've added a new static function, Namespace::isContentQuery(), to Namespace.php (basically just moving existing code in SpecialPopularPages.php into a centralized function). That function has then been added into the SQL queries of all relevant special pages, basically just replacing "page_namespace=".NS_MAIN with "page_namespace ".Namespace::isContentQuery() . A few special cases where more than just one line needed to be changed in the Specialxxx.php are: * On SpecialPopularPages.php and SpecialShortpages.php existing redundant code was removed. * On SpecialUncategorizedpages.php, the default request was changed to be "all content pages" (requested using NULL) instead of NS_MAIN (Uncategorizedtemplates and Uncategorizedcategories still work properly) These changes have been in place at UESP for a year now, so I'm confident that they do work on a live wiki. If anyone would like to see the resulting code in action, you can check some of UESP's special pages, i.e. http://www.uesp.net/wiki/Special:Disambiguations http://www.uesp.net/wiki/Special:Lonelypages http://www.uesp.net/wiki/Special:Deadendpages http://www.uesp.net/wiki/Special:DoubleRedirects The only caveat is that UESP is still running Mediawiki 1.10.0 (in part because we have numerous code modifications like this that make upgrading unbearably difficult, thus the interest in getting some of the modifications added to mediawiki). However, the relevant code hasn't changed much since 1.10. The attached patch was created for 1.14, and I did some basic tests on the 1.14 configuration to check that the changes work. -- Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug. You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikibugs-l
