$a['onload'] = $wgOut->getOnloadHandler();
$a['class'] =
'mediawiki' .
- ' '.$this->getNamespaceClasses( $wgTitle ) .
' '.( $wgContLang->isRTL() ? "rtl" : "ltr" ).
- ' '.Sanitizer::escapeClass( 'page-'.$wgTitle->getPrefixedText() ).
+ ' '.$this->getPageClasses( $wgTitle ) .
' skin-'. Sanitizer::escapeClass( $this->getSkinName( ) );
return $a;
}
- function getNamespaceClasses( $title ) {
+ function getPageClasses( $title ) {
$numeric = 'ns-'.$title->getNamespace();
if( $title->getNamespace() == NS_SPECIAL ) {
$type = "ns-special";
} else {
$type = "ns-subject";
}
- return "$numeric $type";
+ $name = Sanitizer::escapeClass( 'page-'.$title->getPrefixedText() );
+ return "$numeric $type $name";
}
/**
$tpl->set( 'title', $wgOut->getPageTitle() );
$tpl->set( 'pagetitle', $wgOut->getHTMLTitle() );
$tpl->set( 'displaytitle', $wgOut->mPageLinkTitle );
- $tpl->set( 'pageclass', Sanitizer::escapeClass( 'page-'.$this->mTitle->getPrefixedText() ) );
+ $tpl->set( 'pageclass', $this->getPageClasses( $this->mTitle ) );
$tpl->set( 'skinnameclass', ( "skin-" . Sanitizer::escapeClass( $this->getSkinName ( ) ) ) );
$nsname = isset( $wgCanonicalNamespaceNames[ $this->mTitle->getNamespace() ] ) ?
$tpl->set( 'handheld', $wgRequest->getBool( 'handheld' ) );
$tpl->set( 'csslinks', $this->buildCssLinks() );
$tpl->setRef( 'loggedin', $this->loggedin );
- $tpl->set( 'nsclass', $this->getNamespaceClasses( $this->mTitle ) );
$tpl->set('notspecialpage', $this->mTitle->getNamespace() != NS_SPECIAL);
/* XXX currently unused, might get useful later
$tpl->set( "editable", ($this->mTitle->getNamespace() != NS_SPECIAL ) );
</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') ?> <?php $this->text('skinnameclass') ?>">
+ class="mediawiki <?php $this->text('dir') ?> <?php $this->text('pageclass') ?> <?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('skinnameclass') ?>">
+ class="mediawiki <?php $this->text('dir') ?> <?php $this->text('pageclass') ?> <?php $this->text('skinnameclass') ?>">
<div id="globalWrapper">
<div id="column-content">
<div id="content">