Add option to hide redirects on Special:Allpages and Special:Prefixindex
Closed, ResolvedPublic

Description

Please add a new option to Special:Prefixindex to "Hide redirects"


Version: unspecified
Severity: enhancement

Details

Reference
bz30963
bzimport set Reference to bz30963.

Created attachment 9590
Patch against trunk

attachment nords.patch ignored as obsolete

ichu.ramesh wrote:

Reply to:

<<MrBlueSky :

Patch against trunk>>


I have done your code changes in my localhost but am unable to execute it since I get the below error :

""Notice: Undefined variable: request in C:\xampp\htdocs\mediawiki-1.18.0\includes\specials\SpecialPrefixindex.php on line 52

Fatal error: Call to a member function getBool() on a non-object in C:\xampp\htdocs\mediawiki-1.18.0\includes\specials\SpecialPrefixindex.php on line 52""

Could you just tell me that where have you declared the function getBool()??

attachment nords.patch ignored as obsolete

getBool() is in WebRequest. But the patch will only work when applied to version 1.19 (trunk).

sumanah wrote:

MrBlueSky, just wanted to let you know I've asked a developer to review your patch fairly soon. Thanks and sorry for the wait!

brion added a comment.Dec 16 2011, 9:10 PM

Try to add new function parameters at the end, rather than in the middle: this'll make it easier on any callers you might not have updated or envisioned.

Since a lot of the implementation and UI is shared between Allpages & Prefixindex, I'd also recommend going ahead and adding the checkbox on Allpages too.

Otherwise looks ok -- go ahead and fix those up and I think it's good to merge.

sumanah wrote:

Marking reviewed till MrBlueSky responds to code critique.

Created attachment 9733
Patch against trunk

Option added to both Prefixindex and Allpages.

BWT, I noticed that when you submit an empty form on Allpages it takes you to a list of pages instead of showing the overview again (like it does in 1.18). This change seem to be caused by r102406 and might be fixed by:

86c86

< } elseif( $from !== null && $to == null ) {

		} elseif( $from !== null && $to === null ) {

But i'm not sure whether the change was intended and whether this is the best way to fix it.

Attached: spec_prefixindex_hiderds.patch

Didn't check the patch but the default should be not showing redirects.

Same would be useful for Special:Allpages (worth an own bug report?)

Can I ask on the progress of this patch, it would come in very useful.

(In reply to comment #9)

Can I ask on the progress of this patch, it would come in very useful.

I'll submit/commit the patch after the move to git, which is scheduled later this month. It should be no problem to get this functionality on Special:Prefixindex and Special:Allpages in version 1.20.

Done in gerrit change #3886

  • Bug 7204 has been marked as a duplicate of this bug. ***

Add Comment