[See http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/examples/Content_action.php
for an example]
+'SkinTemplateNavigation': Alter the structured navigation links in SkinTemplates
+&$links: Structured navigation links
+This is used to alter the navigation for skins which use buildNavigationUrls such as Vector.
+
'SkinTemplateOutputPageBeforeExec': Before SkinTemplate::outputPage()
starts page output
&$sktemplate: SkinTemplate object
'UserLoginMailPassword': Block users from emailing passwords
$name: the username to email the password of.
-&$error: out-param ÐÊthe error message to return.
+&$error: out-param ��the error message to return.
'UserLogout': before a user logs out
$user: the user object that is about to be logged out
'actions' => array(),
'variants' => array()
);
-
+
// Detects parameters
$action = $wgRequest->getVal( 'action', 'view' );
$section = $wgRequest->getVal( 'section' );
$isTalk = $this->mTitle->isTalkPage();
// Generates XML IDs from namespace names
- $subjectId = $wgContLang->lc( $this->mTitle->getSubjectNsText() );
+ $subjectId = $wgContLang->lc($wgCanonicalNamespaceNames[MWNamespace::getSubject($this->mTitle->getNamespace())]);
+
if ( $subjectId == '' ) {
$subjectId = 'main';
}
- $talkId = "{$subjectId}_talk";
+ if ( $subjectId == 'main' ) {
+ $talkId = 'talk';
+ } else {
+ $talkId = "{$subjectId}_talk";
+ }
$currentId = $isTalk ? $talkId : $subjectId;
// Adds namespace links
$links['namespaces'][$talkId] = $this->tabAction(
$talkPage, 'vector-namespace-talk', $isTalk, '', true
);
-
+
// Adds view view link
if ( $this->mTitle->exists() ) {
$links['views']['view'] = $this->tabAction(
}
wfProfileIn( __METHOD__ . '-edit' );
-
+
// Checks if user can...
if (
// edit the current page
$this->data['view_urls'] = $nav['views'];
$this->data['action_urls'] = $nav['actions'];
$this->data['variant_urls'] = $nav['variants'];
-
+
// Build additional attributes for personal_urls
foreach ( $this->data['personal_urls'] as $key => $item) {
$this->data['personal_urls'][$key]['attributes'] =