X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;ds=sidebyside;f=includes%2Fspecials%2FSpecialSearch.php;h=6c33bb8040d7d28e76ec98325a5d9ad770b67018;hb=29cf2e21b25e0b3c66292082d5b88ca25b33857c;hp=85365f5dd92f6a35b3fec4be19f3d9b6ae493562;hpb=cddcb353fb67171fefe4cd4277b4e138d78fcdcd;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/specials/SpecialSearch.php b/includes/specials/SpecialSearch.php index 85365f5dd9..6c33bb8040 100644 --- a/includes/specials/SpecialSearch.php +++ b/includes/specials/SpecialSearch.php @@ -300,7 +300,7 @@ class SpecialSearch extends SpecialPage { ) ); $out->addHtml( - Xml::openElement( 'table', array( 'id'=>'mw-search-top-table', 'border'=>0, 'cellpadding'=>0, 'cellspacing'=>0 ) ) . + Xml::openElement( 'table', array( 'id' => 'mw-search-top-table', 'cellpadding' => 0, 'cellspacing' => 0 ) ) . Xml::openElement( 'tr' ) . Xml::openElement( 'td' ) . "\n" . $this->shortDialog( $term ) . @@ -423,7 +423,7 @@ class SpecialSearch extends SpecialPage { if( $t->isKnown() ) { $messageName = 'searchmenu-exists'; - } elseif( $t->userCan( 'create' ) ) { + } elseif( $t->userCan( 'create', $this->getUser() ) ) { $messageName = 'searchmenu-new'; } else { $messageName = 'searchmenu-new-nocreate'; @@ -449,7 +449,9 @@ class SpecialSearch extends SpecialPage { $out = $this->getOutput(); if( strval( $term ) !== '' ) { $out->setPageTitle( $this->msg( 'searchresults' ) ); - $out->setHTMLTitle( $this->msg( 'pagetitle', $this->msg( 'searchresults-title', $term )->plain() ) ); + $out->setHTMLTitle( $this->msg( 'pagetitle' )->rawParams( + $this->msg( 'searchresults-title' )->rawParams( $term )->text() + ) ); } // add javascript specific to special:search $out->addModules( 'mediawiki.special.search' ); @@ -559,7 +561,7 @@ class SpecialSearch extends SpecialPage { //If page content is not readable, just return the title. //This is not quite safe, but better than showing excerpts from non-readable pages //Note that hiding the entry entirely would screw up paging. - if( !$t->userCan( 'read' ) ) { + if( !$t->userCan( 'read', $this->getUser() ) ) { wfProfileOut( __METHOD__ ); return "
  • {$link}
  • \n"; } @@ -667,7 +669,7 @@ class SpecialSearch extends SpecialPage { return "
  • " . '' . '' . - '' . '
    ' . + '' . $thumb->toHtml( array( 'desc-link' => true ) ) . '' . @@ -868,7 +870,7 @@ class SpecialSearch extends SpecialPage { for( $i = 0; $i < $numRows; $i += 4 ) { $namespaceTables .= Xml::openElement( 'table', - array( 'cellpadding' => 0, 'cellspacing' => 0, 'border' => 0 ) + array( 'cellpadding' => 0, 'cellspacing' => 0 ) ); for( $j = $i; $j < $i + 4 && $j < $numRows; $j++ ) { $namespaceTables .= Xml::tags( 'tr', null, $rows[$j] );