X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fspecials%2FSpecialSpecialpages.php;h=b18b370c6b91ff26dc903de8ff3b323ba7383ee2;hb=787fd04549592c05667b0c733cd963333d6c0920;hp=eaa900723fde0435998b7131e2664c29ac5a5fbd;hpb=8195fd3551c484cfe140fd54ac9c16c2d8c4bc4a;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/specials/SpecialSpecialpages.php b/includes/specials/SpecialSpecialpages.php index eaa900723f..b18b370c6b 100644 --- a/includes/specials/SpecialSpecialpages.php +++ b/includes/specials/SpecialSpecialpages.php @@ -58,19 +58,19 @@ class SpecialSpecialpages extends UnlistedSpecialPage { } /** Put them into a sortable array */ - $groups = array(); + $groups = []; /** @var SpecialPage $page */ foreach ( $pages as $page ) { if ( $page->isListed() ) { $group = $page->getFinalGroupName(); if ( !isset( $groups[$group] ) ) { - $groups[$group] = array(); + $groups[$group] = []; } - $groups[$group][$page->getDescription()] = array( + $groups[$group][$page->getDescription()] = [ $page->getPageTitle(), $page->isRestricted(), $page->isCached() - ); + ]; } } @@ -96,27 +96,19 @@ class SpecialSpecialpages extends UnlistedSpecialPage { $includesCachedPages = false; foreach ( $groups as $group => $sortedPages ) { - $total = count( $sortedPages ); - $middle = ceil( $total / 2 ); - $count = 0; $out->wrapWikiMsg( "

$1

\n", "specialpages-group-$group" ); $out->addHTML( - Html::openElement( - 'table', - array( 'style' => 'width:100%;', 'class' => 'mw-specialpages-table' ) - ) . "\n" . - Html::openElement( 'tr' ) . "\n" . - Html::openElement( 'td', array( 'style' => 'width:30%;vertical-align:top' ) ) . "\n" . - Html::openElement( 'ul' ) . "\n" + Html::openElement( 'div', [ 'class' => 'mw-specialpages-list' ] ) + . '