Christensen, Courtney wrote:
> On Wed, Mar 25, 2009 at 8:43 PM, David Di Biase <[email protected]>
> wrote:
>> I might not have been too articulate in my question. I got it to work with
>> the organisation, I'm just wondering how do I get it to display as
>> "Einstein, Albert" on the category name?
>
> How do you feel about writing PHP? You could do this with an extension to
> CategoryPage.
Not sure about doing it with an extension, but it should be trivial to
kluge. Actually, here's a patch that ought to do it:
--- includes/CategoryPage.php (revision 48416)
+++ includes/CategoryPage.php (working copy)
@@ -189,7 +189,7 @@
*/
function addPage( $title, $sortkey, $pageLength, $isRedirect = false ) {
global $wgContLang;
- $titletext = $wgContLang->convert( $title->getPrefixedText() );
+ $titletext = $wgContLang->convert( $sortkey );
$this->articles[] = $isRedirect
? '<span class="redirect-in-category">' .
$this->getSkin()->makeKnownLinkObj( $title, $titletext ) . '</span>'
: $this->getSkin()->makeSizeLinkObj( $pageLength,
$title, $titletext );
It would be easy to make this depend on a config option, too. If anyone
else thinks that would be a good idea, I can commit it.
--
Ilmari Karonen
_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l