Difference between revisions of "MediaWiki:Common.css"

Line 1: Line 1:
 
/* CSS placed here will be applied to all skins */
 
/* CSS placed here will be applied to all skins */
  
<!-- No [view source] tab for anonymous users -->
+
<!-- No [edit] tab for users who can not edit -->
<?php global $wgUser; if( $wgUser->isAnon() ) { ?>
+
<?php global $wgUser; if( !$wgUser->isAllowed('edit') ) { ?>
 
       <style type="text/css">
 
       <style type="text/css">
         #ca-viewsource { display: none !important; }
+
         #ca-edit { display: none !important; }
 
       </style>  
 
       </style>  
 
     <?php } ?>
 
     <?php } ?>
  
<!-- No [edit] tab for anonymous users -->
+
<!-- No [view source] tab for users who can not edit -->
<?php global $wgUser; if( $wgUser->isAnon() ) { ?>
+
<?php global $wgUser; if( !$wgUser->isAllowed('edit') ) { ?>
 
       <style type="text/css">
 
       <style type="text/css">
         #ca-edit { display: none !important; }
+
         #ca-view { display: none !important; }
 
       </style>  
 
       </style>  
 
     <?php } ?>
 
     <?php } ?>

Revision as of 04:00, 23 January 2018

/* CSS placed here will be applied to all skins */

<!-- No [edit] tab for users who can not edit -->
<?php global $wgUser; if( !$wgUser->isAllowed('edit') ) { ?>
      <style type="text/css">
        #ca-edit { display: none !important; }
      </style> 
    <?php } ?>

<!-- No [view source] tab for users who can not edit -->
<?php global $wgUser; if( !$wgUser->isAllowed('edit') ) { ?>
      <style type="text/css">
        #ca-view { display: none !important; }
      </style> 
    <?php } ?>