Wikia code/includes/specials/SpecialMovepage.php
This page is obsolete. It is being retained for archival purposes. It may document extensions or features that are obsolete and/or no longer supported. Do not rely on the information here being up-to-date. The information shown below refers to the now unmaintained 1.16 MediaWiki release. The current stable release number is 1.42.1. |
--- D:\Programming\SVN\mediawiki\branches\REL1_16\phase3\includes\specials\SpecialMovepage.php 2011-07-18 22:31:17.794921900 +0100
+++ D:\Programming\SVN\wikia\trunk\includes\specials\SpecialMovepage.php 2011-08-17 15:28:16.445312500 +0100
@@ -41,6 +41,9 @@
return;
}
+ $form = null;
+ wfRunHooks( 'MovePageForm', array( &$oldTitle, &$newTitle, &$form ) );
+ if( $form == null )
$form = new MovePageForm( $oldTitle, $newTitle );
if ( 'submit' == $action && $wgRequest->wasPosted()
@@ -195,7 +198,10 @@
}
$wgOut->addHTML(
- Xml::openElement( 'form', array( 'method' => 'post', 'action' => $titleObj->getLocalURL( 'action=submit' ), 'id' => 'movepage' ) ) .
+ Xml::openElement( 'form', array( 'method' => 'post', 'action' => $titleObj->getLocalURL( 'action=submit' ), 'id' => 'movepage' ) )
+ );
+ wfRunHooks( 'ArticleMoveForm', array( &$wgOut ) );
+ $wgOut->addHTML(
Xml::openElement( 'fieldset' ) .
Xml::element( 'legend', null, wfMsg( 'move-page-legend' ) ) .
Xml::openElement( 'table', array( 'border' => '0', 'id' => 'mw-movepage-table' ) ) .
@@ -339,6 +345,10 @@
$ot = $this->oldTitle;
$nt = $this->newTitle;
+ if( ! wfRunHooks( 'SpecialMovepageBeforeMove', array(&$this))) {
+ return;
+ }
+
# Delete to make way if requested
if ( $wgUser->isAllowed( 'delete' ) && $this->deleteAndMove ) {
$article = new Article( $nt );