Index: trunk/phase3/includes/SpecialAllmessages.php |
— | — | @@ -27,8 +27,8 @@ |
28 | 28 | |
29 | 29 | foreach ( $sortedArray as $key => $enMsg ) { |
30 | 30 | $messages[$key]['enmsg'] = $enMsg; |
31 | | - $messages[$key]['statmsg'] = wfMsgNoDb( $key, false ); |
32 | | - $messages[$key]['msg'] = wfMsg ( $key, false ); |
| 31 | + $messages[$key]['statmsg'] = wfMsgNoDbNoConvert( $key ); |
| 32 | + $messages[$key]['msg'] = wfMsgNoConvert ( $key ); |
33 | 33 | } |
34 | 34 | |
35 | 35 | $wgMessageCache->enableTransform(); |
Index: trunk/phase3/includes/GlobalFunctions.php |
— | — | @@ -355,7 +355,7 @@ |
356 | 356 | /** |
357 | 357 | * Get a message from anywhere |
358 | 358 | */ |
359 | | -function wfMsg( $key, $convert=true ) { |
| 359 | +function wfMsg( $key ) { |
360 | 360 | global $wgRequest; |
361 | 361 | if ( $wgRequest->getVal( 'debugmsg' ) ) { |
362 | 362 | if ( $key == 'linktrail' /* a special case where we want to return something specific */ ) |
— | — | @@ -367,21 +367,50 @@ |
368 | 368 | if ( count( $args ) ) { |
369 | 369 | array_shift( $args ); |
370 | 370 | } |
371 | | - return wfMsgReal( $key, $args, true, $convert ); |
| 371 | + return wfMsgReal( $key, $args, true ); |
372 | 372 | } |
373 | 373 | |
374 | 374 | /** |
| 375 | + * Get a message from anywhere, but don't call Language::convert |
| 376 | + */ |
| 377 | +function wfMsgNoConvert( $key ) { |
| 378 | + global $wgRequest; |
| 379 | + if ( $wgRequest->getVal( 'debugmsg' ) ) { |
| 380 | + if ( $key == 'linktrail' /* a special case where we want to return something specific */ ) |
| 381 | + return "/^()(.*)$/sD"; |
| 382 | + else |
| 383 | + return $key; |
| 384 | + } |
| 385 | + $args = func_get_args(); |
| 386 | + if ( count( $args ) ) { |
| 387 | + array_shift( $args ); |
| 388 | + } |
| 389 | + return wfMsgReal( $key, $args, true, false ); |
| 390 | +} |
| 391 | + |
| 392 | +/** |
375 | 393 | * Get a message from the language file |
376 | 394 | */ |
377 | | -function wfMsgNoDB( $key, $convert=true ) { |
| 395 | +function wfMsgNoDB( $key ) { |
378 | 396 | $args = func_get_args(); |
379 | 397 | if ( count( $args ) ) { |
380 | 398 | array_shift( $args ); |
381 | 399 | } |
382 | | - return wfMsgReal( $key, $args, false, $convert ); |
| 400 | + return wfMsgReal( $key, $args, false ); |
383 | 401 | } |
384 | 402 | |
385 | 403 | /** |
| 404 | + * Get a message from the language file, but don't call Language::convert |
| 405 | + */ |
| 406 | +function wfMsgNoDBNoConvert( $key ) { |
| 407 | + $args = func_get_args(); |
| 408 | + if ( count( $args ) ) { |
| 409 | + array_shift( $args ); |
| 410 | + } |
| 411 | + return wfMsgReal( $key, $args, false, false ); |
| 412 | +} |
| 413 | + |
| 414 | +/** |
386 | 415 | * Really get a message |
387 | 416 | */ |
388 | 417 | function wfMsgReal( $key, $args, $useDB, $convert=true ) { |