Page MenuHomeWolfplex

No OneTemporary

diff --git a/Foreground.skin.php b/Foreground.skin.php
index bbc5178..fad7c4a 100755
--- a/Foreground.skin.php
+++ b/Foreground.skin.php
@@ -1,168 +1,173 @@
<?php
/**
* Skin file for skin WikiWonders' Foreground
*
* @file
* @ingroup Skins
*/
class Skinforeground extends SkinTemplate {
public $skinname = 'foreground', $stylename = 'foreground', $template = 'foregroundTemplate', $useHeadElement = true;
public function setupSkinUserCss(OutputPage $out) {
parent::setupSkinUserCss($out);
$out->addHeadItem('ie-meta', '<meta http-equiv="X-UA-Compatible" content="IE=edge" />');
$out->addModuleStyles('skins.foreground');
}
public function initPage( OutputPage $out ) {
global $wgLocalStylePath;
parent::initPage($out);
$viewport_meta = 'width=device-width, user-scalable=yes, initial-scale=1.0';
$out->addMeta('viewport', $viewport_meta);
$out->addModuleScripts('skins.foreground');
}
}
class foregroundTemplate extends BaseTemplate {
public function execute() {
global $wgUser;
wfSuppressWarnings();
$this->html('headelement');
?>
<!-- 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>Menu</span></a></li>
</ul>
<section class="top-bar-section">
<ul class="left">
<li class="divider"></li>
<?php foreach ( $this->getSidebar() as $boxName => $box ) { if ($box['header'] != "Toolbox") { ?>
<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 } } ?>
</li>
<?php } ?>
</ul>
<ul 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' => 'Search...', 'id' => 'searchInput') ); ?>
</div>
<div class="small-4 columns">
<button type="submit" class="button search">Search</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="icon-cogs"></i></a>
<ul class="dropdown">
<?php foreach ( $this->getToolbox() as $key => $item ) { echo $this->makeListItem($key, $item); } ?>
<li id="n-recentchanges"><a href="/wiki/Special:RecentChanges">Recent Changes</a></li>
<li id="n-help"><a href="/wiki/Help:Contents">Help</a></li>
</ul>
</li>
<?php if ($wgUser->isLoggedIn()): ?>
<li class="has-dropdown active"><a href="#"><i class="icon-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']; ?>">Sign In</a>
<?php elseif (isset($this->data['personal_urls']['login'])): ?>
<a href="<?php echo $this->data['personal_urls']['login']['href']; ?>">Sign In</a>
<?php else: ?>
<?php echo Linker::link(Title::newFromText('Special:UserLogin'), 'Sign In'); ?>
<?php endif; ?>
</li>
<?php endif; ?>
</ul>
</section>
</nav>
<div class="row">
<div class="large-12 columns">
<!--[if lt IE 9]>
<div id="siteNotice" class="sitenotice panel radius"><?php echo $this->text('sitename'); ?> may not look as expected in this version of Internet Explorer. We recommend you upgrade to a newer version of Internet Explorer or switch to a browser like Firefox or Chrome.</div>
<![endif]-->
<?php if ( $this->data['sitenotice'] ) { ?><div id="siteNotice" class="sitenotice panel radius"><?php $this->html( 'sitenotice' ); ?></div><?php } ?>
<?php if ( $this->data['newtalk'] ) { ?><div id="usermessage" class="newtalk panel radius"><?php $this->html( 'newtalk' ); ?></div><?php } ?>
</div>
</div>
<div id="mw-js-message" style="display:none;"></div>
<div class="row">
<div class="large-12 columns">
<?php if ($wgUser->isLoggedIn()): ?>
<a href="#" data-dropdown="drop1" class="button dropdown small secondary radius"><i class="icon-cog"><span class="show-for-medium-up">&nbsp;Actions</span></i></a>
<ul id="drop1" class="views large-12 columns f-dropdown">
<?php foreach( $this->data['content_actions'] as $key => $item ) { echo $this->makeListItem($key, $item); } ?>
<?php wfRunHooks( SkinTemplateToolboxEnd, array( &$this, true ) ); ?>
</ul>
<?php endif;
$namespace = str_replace('_', ' ', $this->getSkin()->getTitle()->getNsText());
- if (!empty($namespace)) { ?><h4 class="namespace label"><?php print $namespace; ?></h4><?php } ?>
- <h2 class="title"><?php $this->html('title') ?></h2>
+ $displaytitle = $this->data['title'];
+ if (!empty($namespace)) {
+ $pagetitle = $this->getSkin()->getTitle();
+ $newtitle = str_replace($namespace.':', '', $pagetitle);
+ $displaytitle = str_replace($pagetitle, $newtitle, $displaytitle);
+ ?><h4 class="namespace label"><?php print $namespace; ?></h4><?php } ?>
+ <h2 class="title"><?php print $displaytitle; ?></h2>
<?php if ( $this->data['isarticle'] ) { ?><h3 id="siteSub"><?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="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><?php $this->html( $key ) ?></li>
<?php } ?>
</ul>
<ul> <?php foreach ( $this->getFooterIcons( "nocopyright" ) as $blockName => $footerIcons ) { ?>
<li><?php foreach ( $footerIcons as $icon ) { ?>
<?php echo $this->getSkin()->makeFooterIcon( $icon, 'withoutImage' ); ?>
<?php } ?>
</li>
<?php } ?>
</ul>
</footer>
<div id="mw-js-message" style="display:none;"></div>
<?php $this->printTrail(); ?>
</body>
</html>
<?php
wfRestoreWarnings();
}
}
?>
diff --git a/assets/scripts/foreground.js b/assets/scripts/foreground.js
index c009cfd..11d458b 100644
--- a/assets/scripts/foreground.js
+++ b/assets/scripts/foreground.js
@@ -1,45 +1,37 @@
jQuery(document).ready(function() {
// Add the 'less than IE9' class to appropriate version of IE by checking for their support of cssFloat (true in v9)
if (!jQuery.support.cssFloat) { jQuery('html').addClass('lt-ie9').addClass('no-js'); }
jQuery(document).foundation(function (response) {
console.log(response.errors);
});
jQuery('[id^=ca-nstab] a').addClass('icon-file').text(' ' + jQuery('[id^=ca-nstab] a').text());
jQuery('li#ca-talk a').addClass('icon-comments').text(' ' + jQuery('li#ca-talk a').text());
jQuery('li#ca-edit a').addClass('icon-edit').text(' ' + jQuery('li#ca-edit a').text());
jQuery('li#ca-form_edit a').addClass('icon-edit-sign').text(' ' + jQuery('li#ca-form_edit a').text());
jQuery('li#ca-history a').addClass('icon-archive').text(' ' + jQuery('li#ca-history a').text());
jQuery('li#ca-delete a').addClass('icon-remove').text(' ' + jQuery('li#ca-delete a').text());
jQuery('li#ca-move a').addClass('icon-truck').text(' ' + jQuery('li#ca-move a').text());
jQuery('li#ca-protect a').addClass('icon-shield').text(' ' + jQuery('li#ca-protect a').text());
jQuery('li#ca-unprotect a').addClass('icon-shield').text(' ' + jQuery('li#ca-unprotect a').text());
jQuery('li#ca-watch a').addClass('icon-star-empty').text(' ' + jQuery('li#ca-watch a').text());
jQuery('li#ca-unwatch a').addClass('icon-star').text(' ' + jQuery('li#ca-unwatch a').text());
jQuery('li#ca-purge a').addClass('icon-refresh').text(' ' + jQuery('li#ca-purge a').text());
jQuery('li#t-smwbrowselink a').addClass('icon-eye-open').text(' ' + jQuery('li#t-smwbrowselink a').text());
-
- // Remove Namespaces from Pages Titles
- if ( jQuery("h4.namespace").length) {
- var $namespace = jQuery("h4.namespace").text() + ":";
- jQuery('h2.title').text( jQuery('h2.title').text().replace($namespace,'') );
- }
-
-
// Turn categories into labels
jQuery('#mw-normal-catlinks ul li a').addClass('label');
// Make the Page Action button respond to hover
jQuery('a.button.dropdown').mouseenter(function(){
jQuery('ul#drop1').addClass('open').addClass('right').css('top', '32px').css('left', '785px');
});
jQuery('ul#drop1').mouseleave(function(){
jQuery('ul#drop1').removeClass('open').css('top', '-9999px').css('left', '785px');
});
-});
\ No newline at end of file
+});

File Metadata

Mime Type
text/x-diff
Expires
Thu, Nov 6, 11:34 PM (1 d, 19 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
69287
Default Alt Text
(9 KB)

Event Timeline