Index: trunk/extensions/SendmailToWiki/SendmailToWiki_body.php |
— | — | @@ -97,9 +97,7 @@ |
98 | 98 | function sendError($code, $message, $sendback = false) { |
99 | 99 | if (!$sendback) |
100 | 100 | return; |
101 | | - |
102 | | - global $wgMessageCache, $wgParser; |
103 | | - |
| 101 | + |
104 | 102 | switch ($code) { |
105 | 103 | case 400: header('HTTP/1.1 400 Bad Request'); break; |
106 | 104 | case 403: header('HTTP/1.1 403 Forbidden'); break; |
— | — | @@ -107,10 +105,10 @@ |
108 | 106 | } |
109 | 107 | |
110 | 108 | $out = ''; |
111 | | - $out .= "<h1>".$wgMessageCache->get('errorpagetitle').": $code</h1>\n"; |
112 | | - $out .= "<h2>".$wgMessageCache->get($message)."</h2>\n"; |
| 109 | + $out .= "<h1>".wfMsg( 'errorpagetitle' ).": $code</h1>\n"; |
| 110 | + $out .= "<h2>".wfMsg( $message )."</h2>\n"; |
113 | 111 | |
114 | | - echo $wgParser->replaceVariables($out); |
| 112 | + echo $out; |
115 | 113 | } |
116 | 114 | } |
117 | 115 | |
Index: trunk/extensions/SendmailToWiki/SendmailToWiki.php |
— | — | @@ -30,9 +30,8 @@ |
31 | 31 | $sendmailtowikiPrefix = 'wikipost'; |
32 | 32 | |
33 | 33 | function sendmailtowikiPinValidate( $value, $alldata ) { |
34 | | - global $wgMessageCache; |
35 | 34 | if ($value != '' && strlen($value) != 5) |
36 | | - return $wgMessageCache->get('sendmailtowiki-err-pinlength'); |
| 35 | + return wfMsg( 'sendmailtowiki-err-pinlength' ); |
37 | 36 | return true; |
38 | 37 | } |
39 | 38 | |