|
@@ -19,7 +19,11 @@ class Skinforeground extends SkinTemplate {
|
|
|
'NavWrapperType' => 'divonly',
|
|
|
'showHelpUnderTools' => true,
|
|
|
'showRecentChangesUnderTools' => true,
|
|
|
- 'IeEdgeCode' => 1
|
|
|
+ 'wikiName' => &$GLOBALS['wgSitename'],
|
|
|
+ 'navbarIcon' => false,
|
|
|
+ 'IeEdgeCode' => 1,
|
|
|
+ 'showFooterIcons' => 0,
|
|
|
+ 'addThisFollowPUBID' => ''
|
|
|
);
|
|
|
foreach ($wgForegroundFeaturesDefaults as $fgOption => $fgOptionValue) {
|
|
|
if ( !isset($wgForegroundFeatures[$fgOption]) ) {
|
|
@@ -65,75 +69,98 @@ class foregroundTemplate extends BaseTemplate {
|
|
|
echo "<div id='navwrapper' class='". $wgForegroundFeatures['NavWrapperType']. "'>";
|
|
|
break;
|
|
|
}
|
|
|
+ switch ($wgForegroundFeatures['showFooterIcons']) {
|
|
|
+ case '0':
|
|
|
+ $footerLeftClass = 'small-8 large-centered columns text-center';
|
|
|
+ $footerRightClass = 'large-12 small-12 columns';
|
|
|
+ $poweredbyType = "nocopyright";
|
|
|
+ $poweredbyMakeType = 'withoutImage';
|
|
|
+ break;
|
|
|
+ case '1':
|
|
|
+ $footerLeftClass = 'large-8 small-12 columns';
|
|
|
+ $footerRightClass = 'large-4 small-12 columns';
|
|
|
+ $poweredbyType = "icononly";
|
|
|
+ $poweredbyMakeType = 'withImage';
|
|
|
+ break;
|
|
|
+ }
|
|
|
?>
|
|
|
<!-- START FOREGROUNDTEMPLATE -->
|
|
|
<nav class="top-bar">
|
|
|
- <ul class="title-area">
|
|
|
- <li class="name"><h1><a href="<?php echo $this->data['nav_urls']['mainpage']['href']; ?>"><?php echo $this->text('sitename'); ?></a></h1></li>
|
|
|
- <li class="toggle-topbar menu-icon"><a href="#"><span><?php echo wfMessage( 'foreground-menutitle' )->text(); ?></span></a></li>
|
|
|
- </ul>
|
|
|
-
|
|
|
- <section class="top-bar-section">
|
|
|
-
|
|
|
- <ul id="top-bar-left" class="left">
|
|
|
- <li class="divider"></li>
|
|
|
- <?php foreach ( $this->getSidebar() as $boxName => $box ) { if ( ($box['header'] != wfMessage( 'toolbox' )->text()) ) { ?>
|
|
|
- <li class="has-dropdown active" id='<?php echo Sanitizer::escapeId( $box['id'] ) ?>'<?php echo Linker::tooltip( $box['id'] ) ?>>
|
|
|
- <a href="#"><?php echo htmlspecialchars( $box['header'] ); ?></a>
|
|
|
- <?php if ( is_array( $box['content'] ) ) { ?>
|
|
|
- <ul class="dropdown">
|
|
|
- <?php foreach ( $box['content'] as $key => $item ) { echo $this->makeListItem( $key, $item ); } ?>
|
|
|
- </ul>
|
|
|
- <?php } } ?>
|
|
|
- <?php } ?>
|
|
|
- </ul>
|
|
|
-
|
|
|
- <ul id="top-bar-right" class="right">
|
|
|
- <li class="has-form">
|
|
|
- <form action="<?php $this->text( 'wgScript' ); ?>" id="searchform" class="mw-search">
|
|
|
- <div class="row collapse">
|
|
|
- <div class="small-8 columns">
|
|
|
- <?php echo $this->makeSearchInput(array('placeholder' => wfMessage('searchsuggest-search')->text(), 'id' => 'searchInput') ); ?>
|
|
|
- </div>
|
|
|
- <div class="small-4 columns">
|
|
|
- <button type="submit" class="button search"><?php echo wfMessage( 'search' )->text() ?></button>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </form>
|
|
|
- </li>
|
|
|
- <li class="divider show-for-small"></li>
|
|
|
- <li class="has-form">
|
|
|
-
|
|
|
- <li class="has-dropdown active"><a href="#"><i class="fa fa-cogs"></i></a>
|
|
|
- <ul id="toolbox-dropdown" class="dropdown">
|
|
|
- <?php foreach ( $this->getToolbox() as $key => $item ) { echo $this->makeListItem($key, $item); } ?>
|
|
|
- <?php if ($wgForegroundFeatures['showRecentChangesUnderTools']): ?><li id="n-recentchanges"><?php echo Linker::specialLink('Recentchanges') ?></li><?php endif; ?>
|
|
|
- <?php if ($wgForegroundFeatures['showHelpUnderTools']): ?><li id="n-help" <?php echo Linker::tooltip('help') ?>><a href="/wiki/Help:Contents"><?php echo wfMessage( 'help' )->text() ?></a></li><?php endif; ?>
|
|
|
- </ul>
|
|
|
- </li>
|
|
|
-
|
|
|
- <?php if ($wgUser->isLoggedIn()): ?>
|
|
|
- <li id="personal-tools-dropdown" class="has-dropdown active"><a href="#"><i class="fa fa-user"></i></a>
|
|
|
- <ul class="dropdown">
|
|
|
- <?php foreach ( $this->getPersonalTools() as $key => $item ) { echo $this->makeListItem($key, $item); } ?>
|
|
|
- </ul>
|
|
|
- </li>
|
|
|
-
|
|
|
- <?php else: ?>
|
|
|
+ <ul class="title-area">
|
|
|
+ <li class="name">
|
|
|
+ <h1 class="title-name">
|
|
|
+ <a href="<?php echo $this->data['nav_urls']['mainpage']['href']; ?>">
|
|
|
+ <?php if ($wgForegroundFeatures['navbarIcon'] != '0') { ?>
|
|
|
+ <img alt="<?php echo $this->text('sitename'); ?>" src="<?php echo $this->text('logopath') ?>" style="max-width: 64px;height:auto; max-height:36px; display: inline-block; vertical-align:middle;">
|
|
|
+ <?php } ?>
|
|
|
+ <div class="title-name" style="display: inline-block;"><?php echo $wgForegroundFeatures['wikiName']; ?></div>
|
|
|
+ </a>
|
|
|
+ </h1>
|
|
|
+ </li>
|
|
|
+ <li class="toggle-topbar menu-icon">
|
|
|
+ <a href="#"><span><?php echo wfMessage( 'foreground-menutitle' )->text(); ?></span></a>
|
|
|
+ </li>
|
|
|
+ </ul>
|
|
|
+
|
|
|
+ <section class="top-bar-section">
|
|
|
+
|
|
|
+ <ul id="top-bar-left" class="left">
|
|
|
+ <li class="divider"></li>
|
|
|
+ <?php foreach ( $this->getSidebar() as $boxName => $box ) { if ( ($box['header'] != wfMessage( 'toolbox' )->text()) ) { ?>
|
|
|
+ <li class="has-dropdown active" id='<?php echo Sanitizer::escapeId( $box['id'] ) ?>'<?php echo Linker::tooltip( $box['id'] ) ?>>
|
|
|
+ <a href="#"><?php echo htmlspecialchars( $box['header'] ); ?></a>
|
|
|
+ <?php if ( is_array( $box['content'] ) ) { ?>
|
|
|
+ <ul class="dropdown">
|
|
|
+ <?php foreach ( $box['content'] as $key => $item ) { echo $this->makeListItem( $key, $item ); } ?>
|
|
|
+ </ul>
|
|
|
+ <?php } } ?>
|
|
|
+ <?php } ?>
|
|
|
+ </ul>
|
|
|
+
|
|
|
+ <ul id="top-bar-right" class="right">
|
|
|
+ <li class="has-form">
|
|
|
+ <form action="<?php $this->text( 'wgScript' ); ?>" id="searchform" class="mw-search">
|
|
|
+ <div class="row">
|
|
|
+ <div class="small-12 columns">
|
|
|
+ <?php echo $this->makeSearchInput(array('placeholder' => wfMessage('searchsuggest-search')->text(), 'id' => 'searchInput') ); ?>
|
|
|
+ <button type="submit" class="button search"><?php echo wfMessage( 'search' )->text() ?></button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </form>
|
|
|
+ </li>
|
|
|
+ <li class="divider show-for-small"></li>
|
|
|
+ <li class="has-form">
|
|
|
+
|
|
|
+ <li class="has-dropdown active"><a href="#"><i class="fa fa-cogs"></i></a>
|
|
|
+ <ul id="toolbox-dropdown" class="dropdown">
|
|
|
+ <?php foreach ( $this->getToolbox() as $key => $item ) { echo $this->makeListItem($key, $item); } ?>
|
|
|
+ <?php if ($wgForegroundFeatures['showRecentChangesUnderTools']): ?><li id="n-recentchanges"><?php echo Linker::specialLink('Recentchanges') ?></li><?php endif; ?>
|
|
|
+ <?php if ($wgForegroundFeatures['showHelpUnderTools']): ?><li id="n-help" <?php echo Linker::tooltip('help') ?>><a href="/wiki/Help:Contents"><?php echo wfMessage( 'help' )->text() ?></a></li><?php endif; ?>
|
|
|
+ </ul>
|
|
|
+ </li>
|
|
|
+
|
|
|
+ <?php if ($wgUser->isLoggedIn()): ?>
|
|
|
+ <li id="personal-tools-dropdown" class="has-dropdown active"><a href="#"><i class="fa fa-user"></i></a>
|
|
|
+ <ul class="dropdown">
|
|
|
+ <?php foreach ( $this->getPersonalTools() as $key => $item ) { echo $this->makeListItem($key, $item); } ?>
|
|
|
+ </ul>
|
|
|
+ </li>
|
|
|
+
|
|
|
+ <?php else: ?>
|
|
|
<li>
|
|
|
<?php if (isset($this->data['personal_urls']['anonlogin'])): ?>
|
|
|
- <a href="<?php echo $this->data['personal_urls']['anonlogin']['href']; ?>"><?php echo wfMessage( 'login' )->text() ?></a>
|
|
|
+ <a href="<?php echo $this->data['personal_urls']['anonlogin']['href']; ?>"><?php echo wfMessage( 'login' )->text() ?></a>
|
|
|
<?php elseif (isset($this->data['personal_urls']['login'])): ?>
|
|
|
<a href="<?php echo htmlspecialchars($this->data['personal_urls']['login']['href']); ?>"><?php echo wfMessage( 'login' )->text() ?></a>
|
|
|
- <?php else: ?>
|
|
|
- <?php echo Linker::link(Title::newFromText('Special:UserLogin'), wfMessage( 'login' )->text()); ?>
|
|
|
- <?php endif; ?>
|
|
|
+ <?php else: ?>
|
|
|
+ <?php echo Linker::link(Title::newFromText('Special:UserLogin'), wfMessage( 'login' )->text()); ?>
|
|
|
+ <?php endif; ?>
|
|
|
</li>
|
|
|
|
|
|
- <?php endif; ?>
|
|
|
+ <?php endif; ?>
|
|
|
|
|
|
- </ul>
|
|
|
- </section>
|
|
|
+ </ul>
|
|
|
+ </section>
|
|
|
</nav>
|
|
|
<?php if ($wgForegroundFeatures['NavWrapperType'] != '0') echo "</div>"; ?>
|
|
|
|
|
@@ -174,27 +201,45 @@ class foregroundTemplate extends BaseTemplate {
|
|
|
<?php if ( $this->data['isarticle'] ) { ?><h3 id="tagline"><?php $this->msg( 'tagline' ) ?></h3><?php } ?>
|
|
|
<h5 class="subtitle"><?php $this->html('subtitle') ?></h5>
|
|
|
<div class="clear_both"></div>
|
|
|
- <?php $this->html('bodytext') ?>
|
|
|
+ <div class="mw-bodytext">
|
|
|
+ <?php $this->html('bodytext') ?>
|
|
|
+ <div class="clear_both"></div>
|
|
|
+ </div>
|
|
|
<div class="group"><?php $this->html('catlinks'); ?></div>
|
|
|
<?php $this->html('dataAfterContent'); ?>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
- <footer class="row">
|
|
|
-
|
|
|
- <ul class="large-12 columns">
|
|
|
- <?php foreach ( $this->getFooterLinks( "flat" ) as $key ) { ?>
|
|
|
- <li id="footer-<?php echo $key ?>"><?php $this->html( $key ) ?></li>
|
|
|
- <?php } ?>
|
|
|
- </ul>
|
|
|
- <ul> <?php foreach ( $this->getFooterIcons( "nocopyright" ) as $blockName => $footerIcons ) { ?>
|
|
|
- <li class="<?php echo $blockName ?>"><?php foreach ( $footerIcons as $icon ) { ?>
|
|
|
- <?php echo $this->getSkin()->makeFooterIcon( $icon, 'withoutImage' ); ?>
|
|
|
- <?php } ?>
|
|
|
- </li>
|
|
|
- <?php } ?>
|
|
|
- </ul>
|
|
|
- </footer>
|
|
|
+ <footer class="row">
|
|
|
+ <div id="footer">
|
|
|
+ <?php if ($wgForegroundFeatures['addThisFollowPUBID'] != '') { ?>
|
|
|
+ <div class="social-footer large-12 small-12 columns">
|
|
|
+ <div class="social-links">
|
|
|
+ <!-- Go to www.addthis.com/dashboard to customize your tools -->
|
|
|
+ <div class="addthis_horizontal_follow_toolbox"></div>
|
|
|
+ <script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=<?php echo $wgForegroundFeatures['addThisFollowPUBID'];?>"></script>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <?php } ?>
|
|
|
+ <div id="footer-left" class="<?php echo $footerLeftClass;?>">
|
|
|
+ <ul id="footer-left">
|
|
|
+ <?php foreach ( $this->getFooterLinks( "flat" ) as $key ) { ?>
|
|
|
+ <li id="footer-<?php echo $key ?>"><?php $this->html( $key ) ?></li>
|
|
|
+ <?php } ?>
|
|
|
+ </ul>
|
|
|
+ </div>
|
|
|
+ <div id="footer-right-icons" class="<?php echo $footerRightClass;?>">
|
|
|
+ <ul id="poweredby">
|
|
|
+ <?php foreach ( $this->getFooterIcons( $poweredbyType ) as $blockName => $footerIcons ) { ?>
|
|
|
+ <li class="<?php echo $blockName ?>"><?php foreach ( $footerIcons as $icon ) { ?>
|
|
|
+ <?php echo $this->getSkin()->makeFooterIcon( $icon, $poweredbyMakeType ); ?>
|
|
|
+ <?php } ?>
|
|
|
+ </li>
|
|
|
+ <?php } ?>
|
|
|
+ </ul>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </footer>
|
|
|
|
|
|
</div>
|
|
|
|
|
@@ -207,4 +252,4 @@ class foregroundTemplate extends BaseTemplate {
|
|
|
wfRestoreWarnings();
|
|
|
}
|
|
|
}
|
|
|
-?>
|
|
|
+?>
|