X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FDifferenceEngine.php;h=712690c5f2ca8c277b6034046f880b0ba5698480;hb=98fc03e686f9c0b74cd912a8a5f795fd84401b49;hp=26c09ca1f9c6304e398e1babad699d77a5d91482;hpb=436d389650887ab8b746465f150038a2e484172c;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/DifferenceEngine.php b/includes/DifferenceEngine.php index 26c09ca1f9..712690c5f2 100644 --- a/includes/DifferenceEngine.php +++ b/includes/DifferenceEngine.php @@ -18,7 +18,7 @@ class DifferenceEngine { $t = $wgTitle->getPrefixedText() . " (Diff: {$this->mOldid}, " . "{$this->mNewid})"; - $mtext = str_replace( "$1", $t, wfMsg( "missingarticle" ) ); + $mtext = wfMsg( "missingarticle", $t ); $wgOut->setArticleFlag( false ); if ( ! $this->loadText() ) { @@ -91,8 +91,7 @@ cellpadding=0 cellspacing='4px'> $this->mNewtext = $s->old_text; $t = $wgLang->timeanddate( $s->old_timestamp, true ); - $this->mNewtitle = str_replace( "$1", "{$t}", - wfMsg( "revisionasof" ) ); + $this->mNewtitle = wfMsg( "revisionasof", $t ); } if ( 0 == $this->mOldid ) { $sql = "SELECT old_timestamp,old_text FROM old USE INDEX (name_title_timestamp) WHERE " . @@ -111,8 +110,7 @@ cellpadding=0 cellspacing='4px'> $this->mOldtext = $s->old_text; $t = $wgLang->timeanddate( $s->old_timestamp, true ); - $this->mOldtitle = str_replace( "$1", "{$t}", - wfMsg( "revisionasof" ) ); + $this->mOldtitle = wfMsg( "revisionasof", $t ); return true; } @@ -1059,8 +1057,8 @@ class TableDiffFormatter extends DiffFormatter } function _block_header( $xbeg, $xlen, $ybeg, $ylen ) { - $l1 = str_replace( "$1", $xbeg, wfMsg( "lineno" ) ); - $l2 = str_replace( "$1", $ybeg, wfMsg( "lineno" ) ); + $l1 = wfMsg( "lineno", $xbeg ); + $l2 = wfMsg( "lineno", $ybeg ); $r = "{$l1}\n" . "{$l2}\n";