X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;ds=sidebyside;f=includes%2Fspecials%2FSpecialProtectedtitles.php;h=21bdf02860e8dbdbdff1e928b8a73966004447f0;hb=72f36a8bb3ec8492f82b7bd0c85109ce494acf25;hp=cf2b272c41db2756f31c8a71863fac35af6dcbe2;hpb=853f21b42e95b16c876c94245a5a4645dd982e93;p=lhc%2Fweb%2Fwiklou.git
diff --git a/includes/specials/SpecialProtectedtitles.php b/includes/specials/SpecialProtectedtitles.php
index cf2b272c41..21bdf02860 100644
--- a/includes/specials/SpecialProtectedtitles.php
+++ b/includes/specials/SpecialProtectedtitles.php
@@ -27,7 +27,6 @@
* @ingroup SpecialPage
*/
class SpecialProtectedtitles extends SpecialPage {
-
protected $IdLevel = 'level';
protected $IdType = 'type';
@@ -58,8 +57,8 @@ class SpecialProtectedtitles extends SpecialPage {
if ( $pager->getNumRows() ) {
$this->getOutput()->addHTML(
$pager->getNavigationBar() .
- '
' . $pager->getBody() . '
' .
- $pager->getNavigationBar()
+ '' . $pager->getBody() . '
' .
+ $pager->getNavigationBar()
);
} else {
$this->getOutput()->addWikiMsg( 'protectedtitlesempty' );
@@ -77,29 +76,39 @@ class SpecialProtectedtitles extends SpecialPage {
static $infinity = null;
- if( is_null( $infinity ) ) {
+ if ( is_null( $infinity ) ) {
$infinity = wfGetDB( DB_SLAVE )->getInfinity();
}
$title = Title::makeTitleSafe( $row->pt_namespace, $row->pt_title );
- if( !$title ) {
+ if ( !$title ) {
wfProfileOut( __METHOD__ );
- return Html::rawElement( 'li', array(),
- Html::element( 'span', array( 'class' => 'mw-invalidtitle' ),
- Linker::getInvalidTitleDescription( $this->getContext(), $row->pt_namespace, $row->pt_title ) ) ) . "\n";
+
+ return Html::rawElement(
+ 'li',
+ array(),
+ Html::element(
+ 'span',
+ array( 'class' => 'mw-invalidtitle' ),
+ Linker::getInvalidTitleDescription(
+ $this->getContext(),
+ $row->pt_namespace,
+ $row->pt_title
+ )
+ )
+ ) . "\n";
}
$link = Linker::link( $title );
-
$description_items = array();
-
$protType = $this->msg( 'restriction-level-' . $row->pt_create_perm )->escaped();
-
$description_items[] = $protType;
-
$lang = $this->getLanguage();
- $expiry = strlen( $row->pt_expiry ) ? $lang->formatExpiry( $row->pt_expiry, TS_MW ) : $infinity;
- if( $expiry != $infinity ) {
+ $expiry = strlen( $row->pt_expiry ) ?
+ $lang->formatExpiry( $row->pt_expiry, TS_MW ) :
+ $infinity;
+
+ if ( $expiry != $infinity ) {
$user = $this->getUser();
$description_items[] = $this->msg(
'protect-expiring-local',
@@ -111,6 +120,7 @@ class SpecialProtectedtitles extends SpecialPage {
wfProfileOut( __METHOD__ );
+ // @todo i18n: This should use a comma separator instead of a hard coded comma, right?
return '' . $lang->specialList( $link, implode( $description_items, ', ' ) ) . "\n";
}
@@ -126,6 +136,7 @@ class SpecialProtectedtitles extends SpecialPage {
$action = htmlspecialchars( $wgScript );
$title = $this->getTitle();
$special = htmlspecialchars( $title->getPrefixedDBkey() );
+
return "