summaryrefslogtreecommitdiff
path: root/includes/specials/SpecialUpload.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/specials/SpecialUpload.php')
-rw-r--r--includes/specials/SpecialUpload.php14
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' )