Index: trunk/phase3/includes/DefaultSettings.php |
— | — | @@ -2790,8 +2790,8 @@ |
2791 | 2791 | * <code> |
2792 | 2792 | * $wgExtensionCredits[$type][] = array( |
2793 | 2793 | * 'name' => 'Example extension', |
2794 | | - * 'version' => 1.9, |
2795 | | - * 'path' => __FILE__, |
| 2794 | + * 'version' => 1.9, |
| 2795 | + * 'path' => __FILE__, |
2796 | 2796 | * 'author' => 'Foo Barstein', |
2797 | 2797 | * 'url' => 'http://wwww.example.com/Example%20Extension/', |
2798 | 2798 | * 'description' => 'An example extension', |
— | — | @@ -2800,6 +2800,8 @@ |
2801 | 2801 | * </code> |
2802 | 2802 | * |
2803 | 2803 | * Where $type is 'specialpage', 'parserhook', 'variable', 'media' or 'other'. |
| 2804 | + * Where 'descriptionmsg' can be an array with message key and parameters: |
| 2805 | + * 'descriptionmsg' => array( 'exampleextension-desc', param1, param2, ... ), |
2804 | 2806 | */ |
2805 | 2807 | $wgExtensionCredits = array(); |
2806 | 2808 | /* |
Index: trunk/phase3/includes/specials/SpecialVersion.php |
— | — | @@ -259,10 +259,17 @@ |
260 | 260 | |
261 | 261 | # Look for a localized description |
262 | 262 | if( isset( $descriptionMsg ) ) { |
263 | | - $msg = wfMsg( $descriptionMsg ); |
264 | | - if ( !wfEmptyMsg( $descriptionMsg, $msg ) && $msg != '' ) { |
265 | | - $description = $msg; |
| 263 | + if( is_array( $descriptionMsg ) ) { |
| 264 | + $descriptionMsgKey = $descriptionMsg[0]; // Get the message key |
| 265 | + array_shift( $descriptionMsg ); // Shift out the message key to get the parameters only |
| 266 | + array_map( "htmlspecialchars", $descriptionMsg ); // For sanity |
| 267 | + $msg = wfMsg( $descriptionMsgKey, $descriptionMsg ); |
| 268 | + } else { |
| 269 | + $msg = wfMsg( $descriptionMsg ); |
266 | 270 | } |
| 271 | + if ( !wfEmptyMsg( $descriptionMsg, $msg ) && $msg != '' ) { |
| 272 | + $description = $msg; |
| 273 | + } |
267 | 274 | } |
268 | 275 | |
269 | 276 | if ( $haveSubversion ) { |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -196,6 +196,7 @@ |
197 | 197 | ** If $wgWellFormedXml is set to false, some bytes will be shaved off of HTML |
198 | 198 | output by omitting some things like quotation marks where HTML 5 allows. |
199 | 199 | * Added crop for inline images. |
| 200 | +* The description message in $wgExtensionCredits can be an array with parameters |
200 | 201 | |
201 | 202 | === Bug fixes in 1.16 === |
202 | 203 | |