$classes[] = 'new';
$query = 'action=edit';
}
+
+ $text = wfMsg( $message );
+ if ( $text == "<$message>" ) {
+ $text = wfMsg( 'nstab-main' );
+ }
+
return array(
'class' => implode( ' ', $classes ),
- 'text' => wfMsg( $message ),
+ 'text' => $text,
'href' => $title->getLocalUrl( $query ) );
}
case NS_CATEGORY_TALK:
return 'nstab-category';
default:
- return 'nstab-main';
+ return 'nstab-' . strtolower( $this->mTitle->getNsText() );
}
}
* @access public
*/
function getNamespace() { return $this->mNamespace; }
+ /**
+ * Get the namespace text
+ * @return string
+ * @access public
+ */
+ function getNsText() {
+ global $wgLang;
+ return $wgLang->getNsText( $this->mNamespace );
+ }
/**
* Get the interwiki prefix (or null string)
* @return string