* (bug 25512) Subcategory list should not include category prefix for members.
* (bug 22753) Output from update.php is more clear when things changed, entries
indicating nothing changed are now all prefixed by "..."
+* Page existence is now not revealed (in the colour of the tabs) to users who cannot
+ read the page in question.
=== API changes in 1.17 ===
* (bug 22738) Allow filtering by action type on query=logevent.
$action = $wgRequest->getVal( 'action', 'view' );
$section = $wgRequest->getVal( 'section' );
$content_actions = array();
+ $userCanRead = $this->mTitle->quickUserCan( 'read' );
$prevent_active_tabs = false;
wfRunHooks( 'SkinTemplatePreventOtherActiveTabs', array( &$this, &$prevent_active_tabs ) );
$subjpage,
$nskey,
!$this->mTitle->isTalkPage() && !$prevent_active_tabs,
- '', true
+ '', $userCanRead
);
$content_actions['talk'] = $this->tabAction(
'talk',
$this->mTitle->isTalkPage() && !$prevent_active_tabs,
'',
- true
+ $userCanRead
);
wfProfileIn( __METHOD__ . '-edit' );
);
}
}
- } elseif ( $this->mTitle->hasSourceText() ) {
+ } elseif ( $this->mTitle->hasSourceText() && $userCanRead ) {
$content_actions['viewsource'] = array(
'class' => ($action == 'edit') ? 'selected' : false,
'text' => wfMsg( 'viewsource' ),
wfProfileOut( __METHOD__ . '-edit' );
wfProfileIn( __METHOD__ . '-live' );
- if ( $this->mTitle->exists() ) {
+ if ( $this->mTitle->exists() && $userCanRead ) {
$content_actions['history'] = array(
'class' => ($action == 'history') ? 'selected' : false,
$action = $wgRequest->getVal( 'action', 'view' );
$section = $wgRequest->getVal( 'section' );
+ $userCanRead = $this->mTitle->quickUserCan( 'read' );
+
// Checks if page is some kind of content
if( $this->iscontent ) {
// Gets page objects for the related namespaces
// Adds namespace links
$links['namespaces'][$subjectId] = $this->tabAction(
- $subjectPage, 'nstab-' . $subjectId, !$isTalk, '', true
+ $subjectPage, 'nstab-' . $subjectId, !$isTalk, '', $userCanRead
);
$links['namespaces'][$subjectId]['context'] = 'subject';
$links['namespaces'][$talkId] = $this->tabAction(
- $talkPage, 'talk', $isTalk, '', true
+ $talkPage, 'talk', $isTalk, '', $userCanRead
);
$links['namespaces'][$talkId]['context'] = 'talk';
// Adds view view link
- if ( $this->mTitle->exists() ) {
+ if ( $this->mTitle->exists() && $userCanRead ) {
$links['views']['view'] = $this->tabAction(
$isTalk ? $talkPage : $subjectPage,
'vector-view-view', ( $action == 'view' ), '', true
}
}
// Checks if the page has some kind of viewable content
- } elseif ( $this->mTitle->hasSourceText() ) {
+ } elseif ( $this->mTitle->hasSourceText() && $userCanRead ) {
// Adds view source view link
$links['views']['viewsource'] = array(
'class' => ( $action == 'edit' ) ? 'selected' : false,
wfProfileIn( __METHOD__ . '-live' );
// Checks if the page exists
- if ( $this->mTitle->exists() ) {
+ if ( $this->mTitle->exists() && $userCanRead ) {
// Adds history view link
$links['views']['history'] = array(
'class' => 'collapsible ' . ( ( $action == 'history' ) ? 'selected' : false ),