* (bug 2835) Back out fix for bug 2802, caused regressions in category sort
authorBrion Vibber <brion@users.mediawiki.org>
Thu, 14 Jul 2005 05:45:51 +0000 (05:45 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Thu, 14 Jul 2005 05:45:51 +0000 (05:45 +0000)
RELEASE-NOTES
includes/CategoryPage.php

index 9eb56f1..41c6332 100644 (file)
@@ -565,7 +565,6 @@ of MediaWiki:Newpagetext) to &action=edit, if page is new.
 * (bug 2780) Fix thumbnail generation with GD for new image schema
 * (bug 2791) Slovene numeric format
 * (bug 655) Provide empty search form when searching for nothing
-* (bug 2802) Display more than one character of the sort key
 * Nynorsk numeric format fix
 * (bug 2825) Fix regression in newtalk notifications for anons w/ enotif off
 * (bug 2833) Fix bug in previous fix
@@ -581,6 +580,7 @@ of MediaWiki:Newpagetext) to &action=edit, if page is new.
 * (bug 460) Properly handle <center> tags as a block.
 * (bug 2001) Implement client-side sorting of table fields with JavaScript
 * Undo inconsistent editing behavior change
+* (bug 2835) Back out fix for bug 2802, caused regressions in category sort
 
 
 === Caveats ===
index 4d61eda..bb6314f 100644 (file)
@@ -140,25 +140,9 @@ class CategoryPage extends Article {
                        } else {
                                // Page in this category
                                array_push( $articles, $sk->makeSizeLinkObj( $x->page_len, $title, $wgContLang->convert( $title->getPrefixedText() ) ) ) ;
-                               array_push( $articles_start_char,$wgContLang->convert( $x->cl_sortkey) );
+                               array_push( $articles_start_char, $wgContLang->convert( $wgContLang->firstChar( $x->cl_sortkey ) ) );
                        }
                }
-
-               $root_length = 0;
-               
-               for ($i = 0 ; $i < count($articles) - 1; ++$i){
-                       if ($articles_start_char[$i][$root_length] != $articles_start_char[$i + 1][$root_length] ) {
-                               break;
-                       } elseif (count($articles) - 2 == $i) {
-                               $root_length = $root_length + 1;
-                               $i = -1;
-                       }
-               }
-               
-               for ($i = 0 ; $i < count($articles) ; ++$i) {
-                       $articles_start_char[$i] = $wgContLang->truncate($articles_start_char[$i], $root_length + 1);
-               }
-
                $dbr->freeResult( $res );
 
                if( $flip ) {