From 47bf2bd0247c86c343b9bd5d5bf12e31dc6dbdcf Mon Sep 17 00:00:00 2001 From: Raimond Spekking Date: Wed, 10 Nov 2010 08:18:21 +0000 Subject: [PATCH] * (bug 22463) Add hook 'SkinGetPoweredBy' to make 'powered by' icon customizable Patch by Yaron --- RELEASE-NOTES | 1 + docs/hooks.txt | 3 +++ includes/Skin.php | 6 ++++-- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index c68b843176..7650126fd0 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -201,6 +201,7 @@ LocalSettings.php. The specific bugs are listed below in the general notes. * Special:Search: Add CSS classes to 'none found' and 'create link' messages * Add CSS classes (including namespace and pagename) to the enhanced recent changes/watchlist entries +* (bug 22463) Add hook 'SkinGetPoweredBy' to make 'powered by' icon customizable === Bug fixes in 1.17 === * (bug 17560) Half-broken deletion moved image files to deletion archive diff --git a/docs/hooks.txt b/docs/hooks.txt index 652b90f4df..0bcf00db60 100644 --- a/docs/hooks.txt +++ b/docs/hooks.txt @@ -1461,6 +1461,9 @@ $type: 'normal' or 'history' for old/diff views &$link: overridable HTML link to be passed into the message as $1 &$forContent: overridable flag if copyright footer is shown in content language. +'SkinGetPoweredBy' +&$text: additional 'powered by' icons in HTML + 'SkinSubPageSubtitle': At the beginning of Skin::subPageSubtitle() &$subpages: Subpage links HTML $skin: Skin object diff --git a/includes/Skin.php b/includes/Skin.php index cc1f2f52ea..542f384eb9 100644 --- a/includes/Skin.php +++ b/includes/Skin.php @@ -1550,9 +1550,11 @@ class Skin extends Linker { global $wgStylePath; $url = htmlspecialchars( "$wgStylePath/common/images/poweredby_mediawiki_88x31.png" ); - $img = 'Powered by MediaWiki'; + $text = 'Powered by MediaWiki'; - return $img; + wfRunHooks( 'SkinGetPoweredBy', array( &$text ) ); + + return $text; } function lastModified() { -- 2.20.1