allows having the unprefixed page title as the default category sortkey
* (bug 15079) Add class="ns-talk" / "ns-subject" to <body>. Also added ns-special to
special pages.
+* (bug 15052) Skins should add their name as a class in <body>
=== API changes in 1.14 ===
'mediawiki ns-'.$wgTitle->getNamespace().
' '.( $wgContLang->isRTL() ? "rtl" : "ltr" ).
' '.Sanitizer::escapeClass( 'page-'.$wgTitle->getPrefixedText() ).
- ' '.( $wgTitle->isTalkPage() ? "ns-talk" : ( $wgTitle->isTalkPage() ? "ns-talk" : ( $wgTitle->getNamespace() == NS_SPECIAL ? "ns-special" : "ns-subject" ) ) );
+ ' '.( $wgTitle->isTalkPage() ? "ns-talk" : ( $wgTitle->isTalkPage() ? "ns-talk" : ( $wgTitle->getNamespace() == NS_SPECIAL ? "ns-special" : "ns-subject" ) ) ).
+ ' skin-'. Sanitizer::escapeClass( $this->getSkinName( ) );
return $a;
}
$tpl->set( 'displaytitle', $wgOut->mPageLinkTitle );
$tpl->set( 'pageclass', Sanitizer::escapeClass( 'page-'.$this->mTitle->getPrefixedText() ) );
$tpl->set( 'talkclass', ( $wgTitle->isTalkPage() ? "ns-talk" : ( $wgTitle->getNamespace() == NS_SPECIAL ? "ns-special" : "ns-subject" ) ) );
+ $tpl->set( 'skinnameclass', ( "skin-" . Sanitizer::escapeClass( $this->getSkinName ( ) ) ) );
$nsname = isset( $wgCanonicalNamespaceNames[ $this->mTitle->getNamespace() ] ) ?
$wgCanonicalNamespaceNames[ $this->mTitle->getNamespace() ] :
</head>
<body<?php if($this->data['body_ondblclick']) { ?> ondblclick="<?php $this->text('body_ondblclick') ?>"<?php } ?>
<?php if($this->data['body_onload' ]) { ?> onload="<?php $this->text('body_onload') ?>"<?php } ?>
- class="mediawiki <?php $this->text('nsclass') ?> <?php $this->text('dir') ?> <?php $this->text('pageclass') ?> <?php $this->text('talkclass') ?>">
+ class="mediawiki <?php $this->text('nsclass') ?> <?php $this->text('dir') ?> <?php $this->text('pageclass') ?> <?php $this->text('talkclass') ?> <?php $this->text('skinnameclass') ?>">
<!-- heading -->
<div id="mw_header"><h1 id="firstHeading"><?php $this->data['displaytitle']!=""?$this->html('title'):$this->text('title') ?></h1></div>
</head>
<body<?php if($this->data['body_ondblclick']) { ?> ondblclick="<?php $this->text('body_ondblclick') ?>"<?php } ?>
<?php if($this->data['body_onload']) { ?> onload="<?php $this->text('body_onload') ?>"<?php } ?>
- class="mediawiki <?php $this->text('nsclass') ?> <?php $this->text('dir') ?> <?php $this->text('pageclass') ?> <?php $this->text('talkclass') ?>">
+ class="mediawiki <?php $this->text('nsclass') ?> <?php $this->text('dir') ?> <?php $this->text('pageclass') ?> <?php $this->text('talkclass') ?> <?php $this->text('skinnameclass') ?>">
<div id="globalWrapper">
<div id="column-content">
<div id="content">