Index: trunk/phase3/maintenance/language/checkLanguage.inc |
— | — | @@ -7,6 +7,7 @@ |
8 | 8 | protected $code = null; |
9 | 9 | protected $level = 2; |
10 | 10 | protected $doLinks = false; |
| 11 | + protected $linksPrefix = ''; |
11 | 12 | protected $wikiCode = 'en'; |
12 | 13 | protected $checkAll = false; |
13 | 14 | protected $output = 'plain'; |
— | — | @@ -42,6 +43,10 @@ |
43 | 44 | $this->includeExif = !isset( $options['noexif'] ); |
44 | 45 | $this->checkAll = isset( $options['all'] ); |
45 | 46 | |
| 47 | + if ( isset( $options['prefix'] ) ) { |
| 48 | + $this->linksPrefix = $options['prefix']; |
| 49 | + } |
| 50 | + |
46 | 51 | if ( isset( $options['wikilang'] ) ) { |
47 | 52 | $this->wikiCode = $options['wikilang']; |
48 | 53 | } |
— | — | @@ -190,6 +195,7 @@ |
191 | 196 | * help: Show this help. |
192 | 197 | * level: Show the following display level (default: 2). |
193 | 198 | * links: Link the message values (default off). |
| 199 | + * prefix: prefix to add to links. |
194 | 200 | * wikilang: For the links, what is the content language of the wiki to display the output in (default en). |
195 | 201 | * whitelist: Do only the following checks (form: code,code). |
196 | 202 | * blacklist: Don't do the following checks (form: code,code). |
— | — | @@ -316,9 +322,9 @@ |
317 | 323 | if ( $this->doLinks ) { |
318 | 324 | $displayKey = ucfirst( $key ); |
319 | 325 | if ( $code == $this->wikiCode ) { |
320 | | - return "[[MediaWiki:$displayKey|$key]]"; |
| 326 | + return "[[{$this->linksPrefix}MediaWiki:$displayKey|$key]]"; |
321 | 327 | } else { |
322 | | - return "[[MediaWiki:$displayKey/$code|$key]]"; |
| 328 | + return "[[{$this->linksPrefix}MediaWiki:$displayKey/$code|$key]]"; |
323 | 329 | } |
324 | 330 | } else { |
325 | 331 | return $key; |