diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2015-12-20 09:00:55 +0100 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2015-12-20 09:00:55 +0100 |
commit | a2190ac74dd4d7080b12bab90e552d7aa81209ef (patch) | |
tree | 8b31f38de9882d18df54cf8d9e0de74167a094eb /includes/specials/SpecialUpload.php | |
parent | 15e69f7b20b6596b9148030acce5b59993b95a45 (diff) | |
parent | 257401d8b2cf661adf36c84b0e3fd1cf85e33c22 (diff) |
Merge branch 'mw-1.26'
Diffstat (limited to 'includes/specials/SpecialUpload.php')
-rw-r--r-- | includes/specials/SpecialUpload.php | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/includes/specials/SpecialUpload.php b/includes/specials/SpecialUpload.php index 2e0699af..16f4d161 100644 --- a/includes/specials/SpecialUpload.php +++ b/includes/specials/SpecialUpload.php @@ -152,6 +152,8 @@ class SpecialUpload extends SpecialPage { * @throws UserBlockedError */ public function execute( $par ) { + $this->useTransactionalTimeLimit(); + $this->setHeaders(); $this->outputHeader(); @@ -357,7 +359,7 @@ class SpecialUpload extends SpecialPage { $sessionKey = $this->mUpload->stashSession(); $warningHtml = '<h2>' . $this->msg( 'uploadwarning' )->escaped() . "</h2>\n" - . '<ul class="warning">'; + . '<div class="warningbox"><ul>'; foreach ( $warnings as $warning => $args ) { if ( $warning == 'badfilename' ) { $this->mDesiredDestName = Title::makeTitle( NS_FILE, $args )->getText(); @@ -385,7 +387,7 @@ class SpecialUpload extends SpecialPage { } $warningHtml .= $msg; } - $warningHtml .= "</ul>\n"; + $warningHtml .= "</ul></div>\n"; $warningHtml .= $this->msg( 'uploadwarning-text' )->parseAsBlock(); $form = $this->getUploadForm( $warningHtml, $sessionKey, /* $hideIgnoreWarning */ true ); @@ -795,6 +797,10 @@ class UploadForm extends HTMLForm { protected $mMaxUploadSize = array(); public function __construct( array $options = array(), IContextSource $context = null ) { + if ( $context instanceof IContextSource ) { + $this->setContext( $context ); + } + $this->mWatch = !empty( $options['watch'] ); $this->mForReUpload = !empty( $options['forreupload'] ); $this->mSessionKey = isset( $options['sessionkey'] ) ? $options['sessionkey'] : ''; @@ -821,8 +827,8 @@ class UploadForm extends HTMLForm { # Add a link to edit MediaWik:Licenses if ( $this->getUser()->isAllowed( 'editinterface' ) ) { - $licensesLink = Linker::link( - Title::makeTitle( NS_MEDIAWIKI, 'Licenses' ), + $licensesLink = Linker::linkKnown( + $this->msg( 'licenses' )->inContentLanguage()->getTitle(), $this->msg( 'licenses-edit' )->escaped(), array(), array( 'action' => 'edit' ) |