3 * Modern skin, derived from monobook template.
10 if( !defined( 'MEDIAWIKI' ) )
13 require( dirname(__FILE__
) . '/MonoBook.php' );
16 * Inherit main code from SkinTemplate, set the CSS and template filter.
20 class SkinModern
extends SkinTemplate
{
21 var $skinname = 'modern', $stylename = 'modern',
22 $template = 'ModernTemplate', $useHeadElement = true;
25 * @param $out OutputPage
27 function setupSkinUserCss( OutputPage
$out ){
28 parent
::setupSkinUserCss( $out );
29 $out->addModuleStyles ('skins.modern');
37 class ModernTemplate
extends MonoBookTemplate
{
44 * Template filter callback for Modern skin.
45 * Takes an associative array of data set from a SkinTemplate-based
46 * class, and a wrapper for MediaWiki's localization database, and
47 * outputs a formatted page.
52 $this->skin
= $skin = $this->data
['skin'];
54 // Suppress warnings to prevent notices about missing indexes in $this->data
57 $this->html( 'headelement' );
61 <div id
="mw_header"><h1 id
="firstHeading"><?php
$this->html('title') ?
></h1
></div
>
64 <div id
="mw_contentwrapper">
65 <!-- navigation portlet
-->
66 <?php
$this->cactions(); ?
>
70 <!-- contentholder does nothing by
default, but it allows users to style the text inside
71 the content area without affecting the meaning of
'em' in
#mw_content, which is used
73 <div id
="mw_contentholder">
74 <div
class='mw-topboxes'>
75 <div id
="mw-js-message" style
="display:none;"<?php
$this->html('userlangattributes')?
>></div
>
76 <div
class="mw-topbox" id
="siteSub"><?php
$this->msg('tagline') ?
></div
>
77 <?php
if($this->data
['newtalk'] ) {
78 ?
><div
class="usermessage mw-topbox"><?php
$this->html('newtalk') ?
></div
>
80 <?php
if($this->data
['sitenotice']) {
81 ?
><div
class="mw-topbox" id
="siteNotice"><?php
$this->html('sitenotice') ?
></div
>
85 <div id
="contentSub"<?php
$this->html('userlangattributes') ?
>><?php
$this->html('subtitle') ?
></div
>
87 <?php
if($this->data
['undelete']) { ?
><div id
="contentSub2"><?php
$this->html('undelete') ?
></div
><?php
} ?
>
88 <?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
} ?
>
90 <?php
$this->html('bodytext') ?
>
91 <div
class='mw_clear'></div
>
92 <?php
if($this->data
['catlinks']) { $this->html('catlinks'); } ?
>
93 <?php
$this->html ('dataAfterContent') ?
>
94 </div
><!-- mw_contentholder
-->
95 </div
><!-- mw_content
-->
96 </div
><!-- mw_contentwrapper
-->
98 <div id
="mw_portlets"<?php
$this->html("userlangattributes") ?
>>
101 <?php
$this->renderPortals( $this->data
['sidebar'] ); ?
>
103 </div
><!-- mw_portlets
-->
108 <div
class="mw_clear"></div
>
110 <!-- personal portlet
-->
111 <div
class="portlet" id
="p-personal">
112 <h5
><?php
$this->msg('personaltools') ?
></h5
>
115 <?php
foreach($this->getPersonalTools() as $key => $item) { ?
>
116 <?php
echo $this->makeListItem($key, $item); ?
>
125 <div id
="footer"<?php
$this->html('userlangattributes') ?
>>
128 foreach( $this->getFooterLinks("flat") as $aLink ) {
129 if( isset( $this->data
[$aLink] ) && $this->data
[$aLink] ) {
130 ?
> <li id
="<?php echo$aLink?>"><?php
$this->html($aLink) ?
></li
>
136 foreach ( $this->getFooterIcons("nocopyright") as $blockName => $footerIcons ) { ?
>
137 <div id
="mw_<?php echo htmlspecialchars($blockName); ?>">
139 foreach ( $footerIcons as $icon ) { ?
>
140 <?php
echo $this->skin
->makeFooterIcon( $icon, 'withoutImage' ); ?
>
150 <?php
$this->printTrail(); ?
>
154 } // end of execute() method