Index: trunk/phase3/includes/DefaultSettings.php |
— | — | @@ -2765,8 +2765,8 @@ |
2766 | 2766 | * <code> |
2767 | 2767 | * $wgExtensionCredits[$type][] = array( |
2768 | 2768 | * 'name' => 'Example extension', |
2769 | | - * 'version' => 1.9, |
2770 | | - * 'path' => __FILE__, |
| 2769 | + * 'version' => 1.9, |
| 2770 | + * 'path' => __FILE__, |
2771 | 2771 | * 'author' => 'Foo Barstein', |
2772 | 2772 | * 'url' => 'http://wwww.example.com/Example%20Extension/', |
2773 | 2773 | * 'description' => 'An example extension', |
— | — | @@ -2775,6 +2775,8 @@ |
2776 | 2776 | * </code> |
2777 | 2777 | * |
2778 | 2778 | * Where $type is 'specialpage', 'parserhook', 'variable', 'media' or 'other'. |
| 2779 | + * Where 'descriptionmsg' can be an array with message key and parameters: |
| 2780 | + * 'descriptionmsg' => array( 'exampleextension-desc', param1, param2, ... ), |
2779 | 2781 | */ |
2780 | 2782 | $wgExtensionCredits = array(); |
2781 | 2783 | /* |
Index: trunk/phase3/includes/specials/SpecialVersion.php |
— | — | @@ -473,7 +473,14 @@ |
474 | 474 | |
475 | 475 | # Look for a localized description |
476 | 476 | if( isset( $descriptionMsg ) ) { |
477 | | - $msg = wfMsg( $descriptionMsg ); |
| 477 | + if( is_array( $descriptionMsg ) ) { |
| 478 | + $descriptionMsgKey = $descriptionMsg[0]; // Get the message key |
| 479 | + array_shift( $descriptionMsg ); // Shift out the message key to get the parameters only |
| 480 | + array_map( "htmlspecialchars", $descriptionMsg ); // For sanity |
| 481 | + $msg = wfMsg( $descriptionMsgKey, $descriptionMsg ); |
| 482 | + } else { |
| 483 | + $msg = wfMsg( $descriptionMsg ); |
| 484 | + } |
478 | 485 | if ( !wfEmptyMsg( $descriptionMsg, $msg ) && $msg != '' ) { |
479 | 486 | $description = $msg; |
480 | 487 | } |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -171,6 +171,7 @@ |
172 | 172 | extension version in Special:Version |
173 | 173 | * (bug 20014) Added CSS class "mw-listgrouprights-right-name" is wrapped on the |
174 | 174 | right name in Special:ListGroupRights |
| 175 | +* The description message in $wgExtensionCredits can be an array with parameters |
175 | 176 | |
176 | 177 | === Bug fixes in 1.16 === |
177 | 178 | |