Last modified: 2014-06-25 08:55:23 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 T69035, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 67035 - hideprefix only respected by top-level nodes
hideprefix only respected by top-level nodes
Status: UNCONFIRMED
Product: MediaWiki extensions
Classification: Unclassified
CategoryTree (Other open bugs)
REL1_23-branch
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-06-24 16:45 UTC by Joseph Fitzgerald
Modified: 2014-06-25 08:55 UTC (History)
0 users

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


Attachments

Description Joseph Fitzgerald 2014-06-24 16:45:37 UTC
I'm using hideprefix=always like this:

{{#categorytree:Category:Joefitzcat|mode=pages|hideprefix=always}}

However the Article namespace prefix is being shown in my tree:

-Joefitzcat
---Finncat
-----Article:Finn

I've debugged the javascript ajax and can see that the browser is passing the correct value of "10" for hideprefix.  However, I've debugged the server side by outputting the hideprefix option value in the text.  I changed CategoryTreeFunctions.php lines 656 and 658 to read like this:

if ( $hideprefix ) {
    $label = htmlspecialchars( $title->getText() ) . $this->getOption( 'hideprefix' );
} else {
    $label = htmlspecialchars( $title->getPrefixedText() ) . $this->getOption( 'hideprefix' );
}

This makes my tree look like this:

-Joefitzcat10
---Finncat20
-----Article:Finn20

Somewhere the option to hide prefix always is being reset to the default during ajax calls.

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


Navigation
Links