function showSuccess() {
global $wgOut, $wgRequest, $wgRawHtml;
-
+
$wgOut->setPagetitle( wfMsg( 'movepage' ) );
$wgOut->setSubtitle( wfMsg( 'pagemovedsub' ) );
- $oldtitle = $wgRequest->getVal('oldtitle');
- $newtitle = $wgRequest->getVal('newtitle');
- $talkmoved = $wgRequest->getVal('talkmoved');
- $text = wfMsg( 'pagemovedtext', $oldtitle, $newtitle );
+ $oldText = $wgRequest->getVal('oldtitle');
+ $newText = $wgRequest->getVal('newtitle');
+ $talkmoved = $wgRequest->getVal('talkmoved');
- # Temporarily disable raw html wikitext option out of XSS paranoia
- $marchingantofdoom = $wgRawHtml;
+ $text = wfMsg( 'pagemovedtext', $oldText, $newText );
+
+ $allowHTML = $wgRawHtml;
$wgRawHtml = false;
$wgOut->addWikiText( $text );
- $wgRawHtml = $marchingantofdoom;
+ $wgRawHtml = $allowHTML;
if ( $talkmoved == 1 ) {
$wgOut->addWikiText( wfMsg( 'talkpagemoved' ) );
} elseif( 'articleexists' == $talkmoved ) {
$wgOut->addWikiText( wfMsg( 'talkexists' ) );
} else {
- $ot = Title::newFromURL( $oldtitle );
- if ( ! $ot->isTalkPage() ) {
+ $oldTitle = Title::newFromText( $oldText );
+ if ( !$oldTitle->isTalkPage() ) {
$wgOut->addWikiText( wfMsg( 'talkpagenotmoved', wfMsg( $talkmoved ) ) );
}
}