Index: trunk/extensions/LinkSuggest/LinkSuggest.php |
— | — | @@ -240,11 +240,13 @@ |
241 | 241 | * |
242 | 242 | * @param $namespace integer page namespace ID |
243 | 243 | * @param $title string page title |
244 | | - * @return string formatted title (prefixed with namespace) |
| 244 | + * @return string formatted title (prefixed with localised namespace) |
245 | 245 | */ |
246 | 246 | function wfLinkSuggestFormatTitle( $namespace, $title ) { |
| 247 | + global $wgContLang; |
| 248 | + |
247 | 249 | if ( $namespace != NS_MAIN ) { |
248 | | - $title = MWNamespace::getCanonicalName( $namespace ) . ':' . $title; |
| 250 | + $title = $wgContLang->getNsText( $namespace ) . ':' . $title; |
249 | 251 | } |
250 | 252 | |
251 | 253 | return str_replace( '_', ' ', $title ); |