r77793 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r77792‎ | r77793 | r77794 >
Date:10:58, 5 December 2010
Author:dantman
Status:deferred
Tags:
Comment:
Folowup r77763, add documentation for $wgFooterIcons.
Modified paths:
  • /trunk/phase3/includes/DefaultSettings.php (modified) (history)
  • /trunk/phase3/includes/Skin.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/DefaultSettings.php
@@ -2267,6 +2267,21 @@
22682268 * You can add new icons to the built in copyright or poweredby, or you can create
22692269 * a new block. Though note that you may need to add some custom css to get good styling
22702270 * of new blocks in monobook. vector and modern should work without any special css.
 2271+ *
 2272+ * $wgFooterIcons itself is a key/value array. The key being the name of a block that
 2273+ * icons will be wrapped in. The final id varries by skin.
 2274+ * The value being a key/value array of icons. The key may or may not be used by the
 2275+ * skin but it can be used to find the icon and unset it or change the icon if needed.
 2276+ * The innermost array has the following keys:
 2277+ * src: An absolute url to the image to use for the icon, this is recommended
 2278+ * but not required, however some skins will ignore icons without an image
 2279+ * url: The url to use in the <a> arround the text or icon, if not set an <a> will not be outputted
 2280+ * alt: This is the text form of the icon, it will be displayed without an image in
 2281+ * skins like Modern or if src is not set, and will otherwise be used as
 2282+ * the alt="" for the image. This key is required.
 2283+ * width and height: If the icon specified by src is not of the standard size
 2284+ * you can specify the size of image to use with these keys.
 2285+ * Otherwise they will default to the standard 88x31.
22712286 */
22722287 $wgFooterIcons = array(
22732288 "copyright" => array(
Index: trunk/phase3/includes/Skin.php
@@ -1632,7 +1632,7 @@
16331633
16341634 /**
16351635 * Renders a $wgFooterIcons icon acording to the method's arguments
1636 - * @param $icon Array: The icon to build the html for
 1636+ * @param $icon Array: The icon to build the html for, see $wgFooterIcons for the format of this array
16371637 * @param $withImage Boolean: Whether to use the icon's image or output a text-only footericon
16381638 */
16391639 function makeFooterIcon( $icon, $withImage = 'withImage' ) {

Follow-up revisions

RevisionCommit summaryAuthorDate
r77796Followup r77793, documentation for icon as a string was missing.dantman11:16, 5 December 2010

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r77763Take the footer icon html building common to all 3 skins using r77741 $wgFoot...dantman04:44, 5 December 2010

Status & tagging log