r98722 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r98721‎ | r98722 | r98723 >
Date:21:47, 2 October 2011
Author:catrope
Status:ok
Tags:
Comment:
1.18wmf1: MFT r98713, r98716, r98718, r98719, r98720
Modified paths:
  • /branches/wmf/1.18wmf1/RELEASE-NOTES-1.18 (modified) (history)
  • /branches/wmf/1.18wmf1/includes/specials/SpecialUserlogin.php (modified) (history)
  • /branches/wmf/1.18wmf1/includes/templates/Userlogin.php (modified) (history)
  • /branches/wmf/1.18wmf1/languages/messages/MessagesEn.php (modified) (history)
  • /branches/wmf/1.18wmf1/maintenance/language/messageTypes.inc (modified) (history)
  • /branches/wmf/1.18wmf1/maintenance/language/messages.inc (modified) (history)

Diff [purge]

Index: branches/wmf/1.18wmf1/maintenance/language/messages.inc
@@ -469,8 +469,10 @@
470470 'throttled-mailpassword',
471471 'loginstart',
472472 'loginend',
 473+ 'loginend-https',
473474 'signupstart',
474475 'signupend',
 476+ 'signupend-https',
475477 'mailerror',
476478 'acct_creation_throttle_hit',
477479 'emailauthenticated',
Index: branches/wmf/1.18wmf1/maintenance/language/messageTypes.inc
@@ -105,6 +105,7 @@
106106 'history_copyright',
107107 'licenses',
108108 'loginstart',
 109+ 'loginend-https',
109110 'loginend',
110111 'loginlanguagelinks',
111112 'pear-mail-error',
@@ -128,6 +129,7 @@
129130 'signature-anon',
130131 'signupstart',
131132 'signupend',
 133+ 'signupend-https',
132134 'sitenotice',
133135 'sitesubtitle',
134136 'sitetitle',
Index: branches/wmf/1.18wmf1/RELEASE-NOTES-1.18
@@ -212,7 +212,8 @@
213213 User:getDefaultOptions().
214214 * (bug 30722) Add a new collation that sorts categories in ascii sort order.
215215 * (bug 31293) If Special:Userlogin is loaded over HTTPS, display
216 - MediaWiki:loginend-https instead of MediaWiki:loginend, if it exists
 216+ MediaWiki:loginend-https instead of MediaWiki:loginend, if it's not empty.
 217+ Same for signupend on the account creation page.
217218
218219 === Bug fixes in 1.18 ===
219220 * mw.util.getScript has been implemented (like wfScript in GlobalFunctions.php)
Property changes on: branches/wmf/1.18wmf1/RELEASE-NOTES-1.18
___________________________________________________________________
Modified: svn:mergeinfo
220221 Merged /trunk/phase3/RELEASE-NOTES-1.18:r98713,98716,98718-98720
Index: branches/wmf/1.18wmf1/includes/specials/SpecialUserlogin.php
@@ -1035,13 +1035,21 @@
10361036 $template->set( 'uselang', $this->mLanguage );
10371037 }
10381038
1039 - // Use loginend-https for HTTPS requests if it exists, loginend otherwise
1040 - $httpsMsg = wfMessage( 'loginend-https' );
1041 - if ( WebRequest::detectProtocol() == 'https' && $httpsMsg->exists() ) {
1042 - $template->set( 'loginend', $httpsMsg->parse() );
 1039+ // Use loginend-https for HTTPS requests if it's not blank, loginend otherwise
 1040+ // Ditto for signupend
 1041+ $usingHTTPS = WebRequest::detectProtocol();
 1042+ $loginendHTTPS = wfMessage( 'loginend-https' );
 1043+ $signupendHTTPS = wfMessage( 'signupend-https' );
 1044+ if ( $usingHTTPS && !$loginendHTTPS->isBlank() ) {
 1045+ $template->set( 'loginend', $loginendHTTPS->parse() );
10431046 } else {
10441047 $template->set( 'loginend', wfMessage( 'loginend' )->parse() );
10451048 }
 1049+ if ( $usingHTTPS && !$signupendHTTPS->isBlank() ) {
 1050+ $template->set( 'signupend', $signupendHTTPS->parse() );
 1051+ } else {
 1052+ $template->set( 'signupend', wfMessage( 'signupend' )->parse() );
 1053+ }
10461054
10471055 // Give authentication and captcha plugins a chance to modify the form
10481056 $wgAuth->modifyUITemplate( $template, $this->mType );
Index: branches/wmf/1.18wmf1/includes/templates/Userlogin.php
@@ -377,7 +377,7 @@
378378 <?php if( $this->haveData( 'token' ) ) { ?><input type="hidden" name="wpCreateaccountToken" value="<?php $this->text( 'token' ); ?>" /><?php } ?>
379379 </form>
380380 </div>
381 -<div id="signupend"><?php $this->msgWiki( 'signupend' ); ?></div>
 381+<div id="signupend"><?php $this->html( 'signupend' ); ?></div>
382382 <?php
383383
384384 }
Index: branches/wmf/1.18wmf1/languages/messages/MessagesEn.php
@@ -1111,8 +1111,10 @@
11121112 To prevent abuse, only one password reminder will be sent per {{PLURAL:$1|hour|$1 hours}}.',
11131113 'loginstart' => '', # do not translate or duplicate this message to other languages
11141114 'loginend' => '', # do not translate or duplicate this message to other languages
 1115+'loginend-https' => '', # do not translate or duplicate this message to other languages
11151116 'signupstart' => '{{int:loginstart}}', # do not translate or duplicate this message to other languages
11161117 'signupend' => '{{int:loginend}}', # do not translate or duplicate this message to other languages
 1118+'signupend-https' => '', # do not translate or duplicate this message to other languages
11171119 'mailerror' => 'Error sending mail: $1',
11181120 'acct_creation_throttle_hit' => 'Visitors to this wiki using your IP address have created {{PLURAL:$1|1 account|$1 accounts}} in the last day, which is the maximum allowed in this time period.
11191121 As a result, visitors using this IP address cannot create any more accounts at the moment.',

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r98713Followup r98707: Register new message key and set it to ignore for translatew...raymond20:44, 2 October 2011
r98716Followup r98707, r98713: check for blankness, not nonexistence. Since r98713 ...catrope20:58, 2 October 2011
r98718Followup r98707: apply this logic to signupend too, per a bug comment.catrope21:07, 2 October 2011
r98719Followup r98718: Register new message key with content per chat with Roan and...raymond21:18, 2 October 2011
r98720Fix r98719: in hindsight, this message should be empty by default. Raymond as...catrope21:42, 2 October 2011

Status & tagging log