Index: trunk/extensions/Validator/Validator.i18n.php |
— | — | @@ -15,8 +15,7 @@ |
16 | 16 | * @author Jeroen De Dauw |
17 | 17 | */ |
18 | 18 | $messages['en'] = array( |
19 | | - 'validator_name' => 'Validator', |
20 | | - 'validator-desc' => 'Validator is a MediaWiki extension that provides generic parameter handling support to other extensions', |
| 19 | + 'validator-desc' => 'Provides generic parameter handling support to other extensions', |
21 | 20 | |
22 | 21 | 'validator_error_parameters' => 'The following {{PLURAL:$1|error has|errors have}} been detected in your syntax:', |
23 | 22 | 'validator_warning_parameters' => 'There {{PLURAL:$1|is an error|are errors}} in your syntax.', |
— | — | @@ -41,7 +40,7 @@ |
42 | 41 | |
43 | 42 | 'validator_list_omitted' => 'The {{PLURAL:$2|value|values}} $1 {{PLURAL:$2|has|have}} been omitted.', |
44 | 43 | |
45 | | - // Crtiteria errors for single values & lists |
| 44 | + // Criteria errors for single values & lists |
46 | 45 | 'validator_error_accepts_only' => 'Parameter $1 only accepts {{PLURAL:$3|this value|these values}}: $2.', |
47 | 46 | ); |
48 | 47 | |
Index: trunk/extensions/Validator/Validator.php |
— | — | @@ -37,33 +37,21 @@ |
38 | 38 | // Include the settings file. |
39 | 39 | require_once( $egValidatorDir . 'Validator_Settings.php' ); |
40 | 40 | |
41 | | -// Put the initalization function into the MW extension hook. |
42 | | -$wgExtensionFunctions[] = 'efValidatorSetup'; |
43 | | - |
44 | 41 | // Register the internationalization file. |
45 | 42 | $wgExtensionMessagesFiles['Validator'] = $egValidatorDir . 'Validator.i18n.php'; |
46 | 43 | |
| 44 | +$wgExtensionCredits['other'][] = array( |
| 45 | + 'path' => __FILE__, |
| 46 | + 'name' => 'Validator', |
| 47 | + 'version' => Validator_VERSION, |
| 48 | + 'author' => array( '[http://www.mediawiki.org/wiki/User:Jeroen_De_Dauw Jeroen De Dauw]' ), |
| 49 | + 'url' => 'http://www.mediawiki.org/wiki/Extension:Validator', |
| 50 | + 'descriptionmsg' => 'validator-desc', |
| 51 | +); |
| 52 | + |
47 | 53 | // Autoload the general classes. |
48 | | -$wgAutoloadClasses['Validator'] = $egValidatorDir . 'Validator.class.php'; |
| 54 | +$wgAutoloadClasses['Validator'] = $egValidatorDir . 'Validator.class.php'; |
49 | 55 | $wgAutoloadClasses['ValidatorFunctions'] = $egValidatorDir . 'Validator_Functions.php'; |
50 | 56 | $wgAutoloadClasses['ValidatorFormats'] = $egValidatorDir . 'Validator_Formats.php'; |
51 | 57 | $wgAutoloadClasses['ValidatorManager'] = $egValidatorDir . 'Validator_Manager.php'; |
52 | 58 | $wgAutoloadClasses['TopologicalSort'] = $egValidatorDir . 'TopologicalSort.php'; |
53 | | - |
54 | | -/** |
55 | | - * Initialization function for the Validator extension. |
56 | | - */ |
57 | | -function efValidatorSetup() { |
58 | | - global $wgExtensionCredits; |
59 | | - |
60 | | - wfLoadExtensionMessages( 'Validator' ); |
61 | | - |
62 | | - $wgExtensionCredits['other'][] = array( |
63 | | - 'path' => __FILE__, |
64 | | - 'name' => wfMsg( 'validator_name' ), |
65 | | - 'version' => Validator_VERSION, |
66 | | - 'author' => array( '[http://www.mediawiki.org/wiki/User:Jeroen_De_Dauw Jeroen De Dauw]' ), |
67 | | - 'url' => 'http://www.mediawiki.org/wiki/Extension:Validator', |
68 | | - 'descriptionmsg' => 'validator-desc', |
69 | | - ); |
70 | | -} |