From: Andrew Garrett Date: Thu, 5 Mar 2009 01:57:18 +0000 (+0000) Subject: When redlink=1 is specified, and the page exists, redirect to the "view" page. X-Git-Tag: 1.31.0-rc.0~42609 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/ajouter.php?a=commitdiff_plain;h=6860f0814d162ff7b2cb16ffc101986061f8ed71;p=lhc%2Fweb%2Fwiklou.git When redlink=1 is specified, and the page exists, redirect to the "view" page. --- diff --git a/includes/EditPage.php b/includes/EditPage.php index 5f2ce38e42..2a64bb1d68 100644 --- a/includes/EditPage.php +++ b/includes/EditPage.php @@ -403,6 +403,11 @@ class EditPage { } } } + + // If they used redlink=1 and the page exists, redirect to the main article + if ( $wgRequest->getBool( 'redlink' ) && $this->mTitle->exists() ) { + $wgOut->redirect( $this->mTitle->getFullURL() ); + } wfProfileIn( __METHOD__."-business-end" );