r86127 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r86126‎ | r86127 | r86128 >
Date:18:35, 15 April 2011
Author:kaldari
Status:ok (Comments)
Tags:
Comment:
adding useragent reporting to feedback tool, slightly increasing size of message field
Modified paths:
  • /trunk/extensions/UploadWizard/resources/mw.UploadWizard.js (modified) (history)

Diff [purge]

Index: trunk/extensions/UploadWizard/resources/mw.UploadWizard.js
@@ -1270,9 +1270,10 @@
12711271 $j( '#mwe-upwiz-feedback-form div' ).hide(); // remove everything else from the dialog box
12721272 $j( '#mwe-upwiz-feedback-form' ).append ( $j( '<div style="text-align:center;margin:3em 0;"></div>' ).append( gM( 'mwe-upwiz-feedback-adding' ), $j( '<br/>' ), $j( '<img src="http://upload.wikimedia.org/wikipedia/commons/4/42/Loading.gif" />' ) ) );
12731273 var subject = $j( '#mwe-upwiz-feedback-subject' ).val();
1274 - var message = $j( '#mwe-upwiz-feedback-message' ).val();
 1274+ var message = "<!--User agent: "+navigator.userAgent+"-->\n";
 1275+ message += $j( '#mwe-upwiz-feedback-message' ).val();
12751276 if ( message.indexOf( '~~~' ) == -1 ) {
1276 - message = message+' ~~~~';
 1277+ message += ' ~~~~';
12771278 }
12781279 var useTokenToPostFeedback = function( token ) {
12791280 $j.ajax({
@@ -1312,7 +1313,7 @@
13131314 $feedbackForm = $j( '<div id="mwe-upwiz-feedback-form" style="position:relative;"></div>' )
13141315 .append( $j( '<div style="margin-top:0.4em;"></div>' ).append( $j( '<small></small>' ).msg( 'mwe-upwiz-feedback-note', feedbackLink ) ) )
13151316 .append( $j( '<div style="margin-top:1em;"></div>' ).append( gM( 'mwe-upwiz-feedback-subject' ), $j( '<br/>' ), $j( '<input type="text" id="mwe-upwiz-feedback-subject" name="subject" maxlength="60" style="width:99%;"/>' ) ) )
1316 - .append( $j( '<div style="margin-top:0.4em;"></div>' ).append( gM( 'mwe-upwiz-feedback-message' ), $j( '<br/>' ), $j( '<textarea name="message" id="mwe-upwiz-feedback-message" style="width:99%;" rows="4" cols="60"></textarea>' ) ) )
 1317+ .append( $j( '<div style="margin-top:0.4em;"></div>' ).append( gM( 'mwe-upwiz-feedback-message' ), $j( '<br/>' ), $j( '<textarea name="message" id="mwe-upwiz-feedback-message" style="width:99%;" rows="5" cols="60"></textarea>' ) ) )
13171318 .dialog({
13181319 width: 500,
13191320 autoOpen: false,

Comments

#Comment by NeilK (talk | contribs)   18:41, 25 April 2011

There was a global introduced here, but it was fixed later on in r86868

#Comment by Kaldari (talk | contribs)   21:03, 25 April 2011

It was still declared locally: var message = "\n";

Status & tagging log