Index: trunk/extensions/SiteMatrix/SiteMatrix.php |
— | — | @@ -14,6 +14,7 @@ |
15 | 15 | 'path' => __FILE__, |
16 | 16 | 'name' => 'SiteMatrix', |
17 | 17 | 'author' => array( 'Tim Starling', 'Brion Vibber', 'Victor Vasiliev', 'Alexandre Emsenhuber' ), |
| 18 | + 'version' => '1.1', |
18 | 19 | 'url' => 'http://www.mediawiki.org/wiki/Extension:SiteMatrix', |
19 | 20 | 'descriptionmsg' => 'sitematrix-desc', |
20 | 21 | ); |
Index: trunk/extensions/SiteMatrix/SiteMatrix_body.php |
— | — | @@ -306,44 +306,6 @@ |
307 | 307 | $localLanguageNames = array(); |
308 | 308 | } |
309 | 309 | |
310 | | - if( $wgRequest->getVal( 'action' ) == 'raw' ){ |
311 | | - $wgOut->disable(); |
312 | | - $count = $matrix->getCount(); |
313 | | - header( 'Content-Type: text/xml; charset=utf-8' ); |
314 | | - echo "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n"; |
315 | | - echo "\t<sitematrix size=\"{$count}\">\n"; |
316 | | - foreach ( $matrix->getLangList() as $lang ) { |
317 | | - $langhost = str_replace( '_', '-', $lang ); |
318 | | - $attribs = array( |
319 | | - 'code' => $langhost, |
320 | | - 'name' => $langNames[$lang], |
321 | | - ); |
322 | | - if( isset( $localLanguageNames[$lang] ) ) { |
323 | | - $attribs['localname'] = $localLanguageNames[$lang]; |
324 | | - } |
325 | | - echo "\t\t" . Xml::openElement( 'language', $attribs ) . "\n"; |
326 | | - foreach ( $matrix->getSites() as $site ) { |
327 | | - if ( $matrix->exist( $lang, $site ) ) { |
328 | | - $url = $matrix->getUrl( $lang, $site ); |
329 | | - echo "\t\t\t<site code=\"{$site}\" url=\"{$url}\" />\n"; |
330 | | - } |
331 | | - } |
332 | | - echo "\t\t</language>\n"; |
333 | | - } |
334 | | - echo "\t<specials>\n"; |
335 | | - foreach ( $matrix->getSpecials() as $special ) { |
336 | | - list( $lang, $site ) = $special; |
337 | | - $langhost = str_replace( '_', '-', $lang ); |
338 | | - if( $site != 'wiki' ) $langhost .= $site; |
339 | | - $url = $matrix->getUrl( $lang, $site ); |
340 | | - |
341 | | - echo "\t\t<special code=\"{$langhost}\" url=\"{$url}\" />\n"; |
342 | | - } |
343 | | - echo "\t</specials>\n"; |
344 | | - echo "\t</sitematrix>\n"; |
345 | | - return; |
346 | | - } |
347 | | - |
348 | 310 | # Construct the HTML |
349 | 311 | |
350 | 312 | # Header row |