MediaWiki:Common.css: Difference between revisions

From OneM2M-Hackathon-Dallas-2018
(Created page with "→‎CSS placed here will be applied to all skins: $wgHooks['SkinTemplateSetupPageCss'][] = 'wfHideVariousTabsFromAnonymous'; function wfHideVariousTabsFromAnonymous( &$hidet...")
 
No edit summary
Line 1: Line 1:
/* CSS placed here will be applied to all skins */
/* CSS placed here will be applied to all skins */
$wgHooks['SkinTemplateSetupPageCss'][] = 'wfHideVariousTabsFromAnonymous';
body.Main_Page li#ca-talk { display:none!important; }
 
function wfHideVariousTabsFromAnonymous( &$hidetabcss ) {
global $wgUser;
 
if ( !$wgUser->isLoggedIn() ) {
/* $hidetabcss .= 'li#ca-history, li#ca-viewsource, li#ca-edit, li#ca-talk, .vectorMenu { display: none; }'; */
                $hidetabcss .= 'li#ca-history, li#ca-viewsource, li#ca-talk, .vectorMenu { display: none; }';
}
 
return true;
}

Revision as of 16:03, 16 February 2018

/* CSS placed here will be applied to all skins */
body.Main_Page li#ca-talk { display:none!important; }