MediaWiki  REL1_19
Modern.php
Go to the documentation of this file.
00001 <?php
00010 if( !defined( 'MEDIAWIKI' ) )
00011         die( -1 );
00012 
00013 require( dirname(__FILE__) . '/MonoBook.php' );
00014 
00020 class SkinModern extends SkinTemplate {
00021         var $skinname = 'modern', $stylename = 'modern',
00022                 $template = 'ModernTemplate', $useHeadElement = true;
00023 
00027         function setupSkinUserCss( OutputPage $out ){
00028                 parent::setupSkinUserCss( $out );
00029                 $out->addModuleStyles ('skins.modern');
00030         }
00031 }
00032 
00037 class ModernTemplate extends MonoBookTemplate {
00038 
00047         function execute() {
00048                 // Suppress warnings to prevent notices about missing indexes in $this->data
00049                 wfSuppressWarnings();
00050 
00051                 $this->html( 'headelement' );
00052 ?>
00053 
00054         <!-- heading -->
00055         <div id="mw_header"><h1 id="firstHeading"><span dir="auto"><?php $this->html('title') ?></span></h1></div>
00056 
00057         <div id="mw_main">
00058         <div id="mw_contentwrapper">
00059         <!-- navigation portlet -->
00060 <?php $this->cactions(); ?>
00061 
00062         <!-- content -->
00063         <div id="mw_content">
00064         <!-- contentholder does nothing by default, but it allows users to style the text inside
00065              the content area without affecting the meaning of 'em' in #mw_content, which is used
00066              for the margins -->
00067         <div id="mw_contentholder">
00068                 <div class='mw-topboxes'>
00069                         <div id="mw-js-message" style="display:none;"<?php $this->html('userlangattributes')?>></div>
00070                         <div class="mw-topbox" id="siteSub"><?php $this->msg('tagline') ?></div>
00071                         <?php if($this->data['newtalk'] ) {
00072                                 ?><div class="usermessage mw-topbox"><?php $this->html('newtalk')  ?></div>
00073                         <?php } ?>
00074                         <?php if($this->data['sitenotice']) {
00075                                 ?><div class="mw-topbox" id="siteNotice"><?php $this->html('sitenotice') ?></div>
00076                         <?php } ?>
00077                 </div>
00078 
00079                 <div id="contentSub"<?php $this->html('userlangattributes') ?>><?php $this->html('subtitle') ?></div>
00080 
00081                 <?php if($this->data['undelete']) { ?><div id="contentSub2"><?php     $this->html('undelete') ?></div><?php } ?>
00082                 <?php if($this->data['showjumplinks']) { ?><div id="jump-to-nav"><?php $this->msg('jumpto') ?> <a href="#mw_portlets"><?php $this->msg('jumptonavigation') ?></a>, <a href="#searchInput"><?php $this->msg('jumptosearch') ?></a></div><?php } ?>
00083 
00084                 <?php $this->html('bodytext') ?>
00085                 <div class='mw_clear'></div>
00086                 <?php if($this->data['catlinks']) { $this->html('catlinks'); } ?>
00087                 <?php $this->html ('dataAfterContent') ?>
00088         </div><!-- mw_contentholder -->
00089         </div><!-- mw_content -->
00090         </div><!-- mw_contentwrapper -->
00091 
00092         <div id="mw_portlets"<?php $this->html("userlangattributes") ?>>
00093 
00094         <!-- portlets -->
00095         <?php $this->renderPortals( $this->data['sidebar'] ); ?>
00096 
00097         </div><!-- mw_portlets -->
00098 
00099 
00100         </div><!-- main -->
00101 
00102         <div class="mw_clear"></div>
00103 
00104         <!-- personal portlet -->
00105         <div class="portlet" id="p-personal">
00106                 <h5><?php $this->msg('personaltools') ?></h5>
00107                 <div class="pBody">
00108                         <ul>
00109 <?php           foreach($this->getPersonalTools() as $key => $item) { ?>
00110                                 <?php echo $this->makeListItem($key, $item); ?>
00111 
00112 <?php           } ?>
00113                         </ul>
00114                 </div>
00115         </div>
00116 
00117 
00118         <!-- footer -->
00119         <div id="footer"<?php $this->html('userlangattributes') ?>>
00120                         <ul id="f-list">
00121 <?php
00122                 foreach( $this->getFooterLinks("flat") as $aLink ) {
00123                         if( isset( $this->data[$aLink] ) && $this->data[$aLink] ) {
00124 ?>                              <li id="<?php echo$aLink?>"><?php $this->html($aLink) ?></li>
00125 <?php           }
00126                 }
00127 ?>
00128                         </ul>
00129 <?php
00130                 foreach ( $this->getFooterIcons("nocopyright") as $blockName => $footerIcons ) { ?>
00131                         <div id="mw_<?php echo htmlspecialchars($blockName); ?>">
00132 <?php
00133                         foreach ( $footerIcons as $icon ) { ?>
00134                                 <?php echo $this->getSkin()->makeFooterIcon( $icon, 'withoutImage' ); ?>
00135 
00136 <?php
00137                         } ?>
00138                         </div>
00139 <?php
00140                 }
00141 ?>
00142         </div>
00143 
00144         <?php $this->printTrail(); ?>
00145 </body></html>
00146 <?php
00147         wfRestoreWarnings();
00148         } // end of execute() method
00149 } // end of class
00150 
00151