From 9db190c7e736ec8d063187d4241b59feaf7dc2d1 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Wed, 22 Jun 2011 11:28:20 +0200 Subject: update to MediaWiki 1.17.0 --- skins/MonoBook.php | 59 ++++++++++++++++++++++++++++++++++++------------------ 1 file changed, 40 insertions(+), 19 deletions(-) (limited to 'skins/MonoBook.php') diff --git a/skins/MonoBook.php b/skins/MonoBook.php index fdc1684d..95833e56 100644 --- a/skins/MonoBook.php +++ b/skins/MonoBook.php @@ -68,15 +68,36 @@ class MonoBookTemplate extends QuickTemplate { // Suppress warnings to prevent notices about missing indexes in $this->data wfSuppressWarnings(); + // Generate additional footer links + $footerlinks = $this->data["footerlinks"]; + // fold footerlinks into a single array using a bit of trickery + $footerlinks = call_user_func_array('array_merge', array_values($footerlinks)); + // Generate additional footer icons + $footericons = $this->data["footericons"]; + // Unset any icons which don't have an image + foreach ( $footericons as $footerIconsKey => &$footerIconsBlock ) { + foreach ( $footerIconsBlock as $footerIconKey => $footerIcon ) { + if ( !is_string($footerIcon) && !isset($footerIcon["src"]) ) { + unset($footerIconsBlock[$footerIconKey]); + } + } + } + // Redo removal of any empty blocks + foreach ( $footericons as $footerIconsKey => &$footerIconsBlock ) { + if ( count($footerIconsBlock) <= 0 ) { + unset($footericons[$footerIconsKey]); + } + } + $this->html( 'headelement' ); ?>
-
html("specialpageattributes") ?>> +
html("specialpageattributes") ?>> data['sitenotice']) { ?>
html('sitenotice') ?>

html('title') ?>

-

msg('tagline') ?>

+
msg('tagline') ?>
html('userlangattributes') ?>>html('subtitle') ?>
data['undelete']) { ?>
html('undelete') ?>
@@ -164,19 +185,17 @@ class MonoBookTemplate extends QuickTemplate {
@@ -326,7 +347,7 @@ if($this->data['copyrightico']) { ?>