From: Ævar Arnfjörð Bjarmason Date: Fri, 1 Apr 2005 19:55:45 +0000 (+0000) Subject: * (bug 578): renamed $wgDisableUploads => $wgEnableUploads X-Git-Tag: 1.5.0alpha1~428 X-Git-Url: http://git.cyclocoop.org/%24self?a=commitdiff_plain;h=f46e9d8a1d4684b39e915fd266defffdf2cb85b9;p=lhc%2Fweb%2Fwiklou.git * (bug 578): renamed $wgDisableUploads => $wgEnableUploads --- diff --git a/config/index.php b/config/index.php index 64bddeabc3..bb59029b8c 100644 --- a/config/index.php +++ b/config/index.php @@ -1084,7 +1084,7 @@ if ( \$wgCommandLineMode ) { ## To enable image uploads, make sure the 'images' directory ## is writable, then uncomment this: -# \$wgDisableUploads = false; +# \$wgEnableUploads = true; \$wgUseImageResize = {$conf->UseImageResize}; {$magic}\$wgUseImageMagick = true; {$magic}\$wgImageMagickConvertCommand = \"{$convert}\"; diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index 73c858a730..da27ddaf88 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -727,7 +727,7 @@ $wgDisableTextSearch = false; */ $wgDisableSearchUpdate = false; /** Uploads have to be specially set up to be secure */ -$wgDisableUploads = true; +$wgEnableUploads = false; /** * Set to true to enable the upload _link_ while local uploads are disabled. * Assumes that the special page link will be bounced to another server where diff --git a/includes/SkinTemplate.php b/includes/SkinTemplate.php index 476af9c179..c9f0233b10 100644 --- a/includes/SkinTemplate.php +++ b/includes/SkinTemplate.php @@ -724,7 +724,7 @@ class SkinTemplate extends Skin { wfProfileIn( $fname ); global $wgUser, $wgRequest; - global $wgSiteSupportPage, $wgDisableUploads; + global $wgSiteSupportPage, $wgEnableUploads; $action = $wgRequest->getText( 'action' ); $oldid = $wgRequest->getVal( 'oldid' ); @@ -740,7 +740,7 @@ class SkinTemplate extends Skin { // $nav_urls['sitesupport'] = array('href' => $this->makeI18nUrl('sitesupportpage')); $nav_urls['sitesupport'] = array('href' => $wgSiteSupportPage); $nav_urls['help'] = array('href' => $this->makeI18nUrl('helppage')); - if( $this->loggedin && !$wgDisableUploads ) { + if( $this->loggedin && $wgEnableUploads ) { $nav_urls['upload'] = array('href' => $this->makeSpecialUrl('Upload')); } else { $nav_urls['upload'] = false; diff --git a/includes/SpecialSitesettings.php b/includes/SpecialSitesettings.php index 7438e14ca9..87f5559bef 100644 --- a/includes/SpecialSitesettings.php +++ b/includes/SpecialSitesettings.php @@ -109,7 +109,7 @@ class SiteSettingsForm extends HTMLForm { $wgOut->addHTML( $this->fieldset( "sitesettings-images" , $this->checkbox( 'wgAllowExternalImages' ) . $this->fieldset( 'sitesettings-images-upload' , - $this->checkbox( 'wgDisableUploads' ) . + $this->checkbox( 'wgEnableUploads' ) . $this->checkbox( 'wgRemoteUploads' ) . $this->arraybox( 'wgFileExtensions' ) . $this->arraybox( 'wgFileBlacklist' ) . diff --git a/includes/SpecialUpload.php b/includes/SpecialUpload.php index 0b53dbd70f..89509de668 100644 --- a/includes/SpecialUpload.php +++ b/includes/SpecialUpload.php @@ -88,10 +88,10 @@ class UploadForm { */ function execute() { global $wgUser, $wgOut; - global $wgDisableUploads; + global $wgEnableUploads; /** Show an error message if file upload is disabled */ - if( $wgDisableUploads ) { + if( ! $wgEnableUploads ) { $wgOut->addWikiText( wfMsg( 'uploaddisabled' ) ); return; } diff --git a/skins/CologneBlue.php b/skins/CologneBlue.php index 8571b4beed..1481cb85fa 100644 --- a/skins/CologneBlue.php +++ b/skins/CologneBlue.php @@ -171,7 +171,7 @@ class SkinCologneBlue extends Skin { */ function quickBar() { - global $wgOut, $wgTitle, $wgUser, $wgLang, $wgContLang, $wgDisableUploads, $wgNavigationLinks; + global $wgOut, $wgTitle, $wgUser, $wgLang, $wgContLang, $wgEnableUploads, $wgNavigationLinks; $tns=$wgTitle->getNamespace(); @@ -268,7 +268,7 @@ class SkinCologneBlue extends Skin { . $sep . $this->specialLink( "imagelist" ) . $sep . $this->specialLink( "statistics" ) . $sep . $this->bugReportsLink(); - if ( $wgUser->isLoggedIn() && !$wgDisableUploads ) { + if ( $wgUser->isLoggedIn() && $wgEnableUploads ) { $s .= $sep . $this->specialLink( "upload" ); } global $wgSiteSupportPage; diff --git a/skins/Standard.php b/skins/Standard.php index 820b9f4e04..7579bdcd8c 100644 --- a/skins/Standard.php +++ b/skins/Standard.php @@ -132,7 +132,7 @@ class SkinStandard extends Skin { function quickBar() { global $wgOut, $wgTitle, $wgUser, $wgRequest, $wgContLang; - global $wgDisableUploads, $wgRemoteUploads, $wgNavigationLinks; + global $wgEnableUploads, $wgRemoteUploads, $wgNavigationLinks; $fname = 'Skin::quickBar'; wfProfileIn( $fname ); @@ -261,7 +261,7 @@ class SkinStandard extends Skin { $s .= "\n

"; } - if ( $wgUser->isLoggedIn() && ( !$wgDisableUploads || $wgRemoteUploads ) ) { + if ( $wgUser->isLoggedIn() && ( $wgEnableUploads || $wgRemoteUploads ) ) { $s .= $this->specialLink( 'upload' ) . $sep; } $s .= $this->specialLink( 'specialpages' )