Index: trunk/extensions/SemanticMediaWiki/includes/export/SMW_Exporter.php |
— | — | @@ -250,8 +250,12 @@ |
251 | 251 | ( in_array( $localname[0], array( '-', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9' ) ) ) ) { |
252 | 252 | $namespace = '&wiki;'; |
253 | 253 | $namespaceid = 'wiki'; |
254 | | - $nsText = str_replace( ' ', '_', $wgContLang->getNSText( $diWikiPage->getNamespace() ) ); |
255 | | - $localname = SMWExporter::encodeURI( wfUrlencode( $nsText . ':' . $diWikiPage->getDBkey() ) ); |
| 254 | + if ( $diWikiPage->getNamespace() !== 0 ) { |
| 255 | + $localname = str_replace( ' ', '_', $wgContLang->getNSText( $diWikiPage->getNamespace() ) ) . ":" . $diWikiPage->getDBkey(); |
| 256 | + } else { |
| 257 | + $localname = $diWikiPage->getDBkey(); |
| 258 | + } |
| 259 | + $localname = SMWExporter::encodeURI( wfUrlencode( $localname ) ); |
256 | 260 | } |
257 | 261 | } |
258 | 262 | |