(bug 27201) fix duplicate IDs in recursive whatlinkshere output
authorIlmari Karonen <vyznev@users.mediawiki.org>
Sun, 6 Feb 2011 18:25:08 +0000 (18:25 +0000)
committerIlmari Karonen <vyznev@users.mediawiki.org>
Sun, 6 Feb 2011 18:25:08 +0000 (18:25 +0000)
RELEASE-NOTES
includes/specials/SpecialWhatlinkshere.php

index 8035d74..1c92c80 100644 (file)
@@ -145,6 +145,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
 * (bug 24650) Fix API to work with categorylinks changes
 * Expose list of skins in meta=siteinfo
 * (bug 26548) Add iiurlparam param to query=imageinfo and query=stashimageinfo
+* (bug 27201) Special:WhatLinksHere output no longer contains duplicate IDs
 
 === Languages updated in 1.18 ===
 
index e0a5d34..276d976 100644 (file)
@@ -239,7 +239,7 @@ class SpecialWhatLinksHere extends SpecialPage {
                        $wgOut->addHTML( $prevnext );
                }
 
-               $wgOut->addHTML( $this->listStart() );
+               $wgOut->addHTML( $this->listStart( $level ) );
                foreach ( $rows as $row ) {
                        $nt = Title::makeTitle( $row->page_namespace, $row->page_title );
 
@@ -259,8 +259,8 @@ class SpecialWhatLinksHere extends SpecialPage {
                }
        }
 
-       protected function listStart() {
-               return Xml::openElement( 'ul', array ( 'id' => 'mw-whatlinkshere-list' ) );
+       protected function listStart( $level ) {
+               return Xml::openElement( 'ul', ( $level ? array() : array( 'id' => 'mw-whatlinkshere-list' ) ) );
        }
 
        protected function listItem( $row, $nt, $notClose = false ) {