summaryrefslogtreecommitdiff
path: root/includes/LogPage.php
diff options
context:
space:
mode:
authorPierre Schmitz <pierre@archlinux.de>2008-03-21 11:49:34 +0100
committerPierre Schmitz <pierre@archlinux.de>2008-03-21 11:49:34 +0100
commit086ae52d12011746a75f5588e877347bc0457352 (patch)
treee73263c7a29d0f94fafb874562610e16eb292ba8 /includes/LogPage.php
parent749e7fb2bae7bbda855de3c9e319435b9f698ff7 (diff)
Update auf MediaWiki 1.12.0
Diffstat (limited to 'includes/LogPage.php')
-rw-r--r--includes/LogPage.php16
1 files changed, 12 insertions, 4 deletions
diff --git a/includes/LogPage.php b/includes/LogPage.php
index 8982b59f..7c89df76 100644
--- a/includes/LogPage.php
+++ b/includes/LogPage.php
@@ -116,9 +116,10 @@ class LogPage {
* @static
*/
public static function logName( $type ) {
- global $wgLogNames;
+ global $wgLogNames, $wgMessageCache;
if( isset( $wgLogNames[$type] ) ) {
+ $wgMessageCache->loadAllMessages();
return str_replace( '_', ' ', wfMsg( $wgLogNames[$type] ) );
} else {
// Bogus log types? Perhaps an extension was removed.
@@ -138,7 +139,7 @@ class LogPage {
/**
* @static
*/
- static function actionText( $type, $action, $title = NULL, $skin = NULL, $params = array(), $filterWikilinks=false, $translate=false ) {
+ static function actionText( $type, $action, $title = NULL, $skin = NULL, $params = array(), $filterWikilinks=false ) {
global $wgLang, $wgContLang, $wgLogActions;
$key = "$type/$action";
@@ -172,6 +173,11 @@ class LogPage {
$text = $wgContLang->ucfirst( $title->getText() );
$titleLink = $skin->makeLinkObj( Title::makeTitle( NS_USER, $text ) );
break;
+ case 'merge':
+ $titleLink = $skin->makeLinkObj( $title, $title->getPrefixedText(), 'redirect=no' );
+ $params[0] = $skin->makeLinkObj( Title::newFromText( $params[0] ), htmlspecialchars( $params[0] ) );
+ $params[1] = $wgLang->timeanddate( $params[1] );
+ break;
default:
$titleLink = $skin->makeLinkObj( $title );
}
@@ -199,8 +205,10 @@ class LogPage {
} else {
array_unshift( $params, $titleLink );
if ( $key == 'block/block' ) {
- if ( $translate ) {
- $params[1] = $wgLang->translateBlockExpiry( $params[1] );
+ if ( $skin ) {
+ $params[1] = '<span title="' . htmlspecialchars( $params[1] ). '">' . $wgLang->translateBlockExpiry( $params[1] ) . '</span>';
+ } else {
+ $params[1] = $wgContLang->translateBlockExpiry( $params[1] );
}
$params[2] = isset( $params[2] )
? self::formatBlockFlags( $params[2] )