r64367 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r64366‎ | r64367 | r64368 >
Date:22:44, 29 March 2010
Author:platonides
Status:ok
Tags:
Comment:
(bug 21520) Anonymous previews now also give a warning about not being
logged in (anonpreviewwarning).
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/EditPage.php (modified) (history)
  • /trunk/phase3/languages/messages/MessagesEn.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/EditPage.php
@@ -1401,8 +1401,12 @@
14021402
14031403 if ( wfReadOnly() ) {
14041404 $wgOut->wrapWikiMsg( "<div id=\"mw-read-only-warning\">\n$1\n</div>", array( 'readonlywarning', wfReadOnlyReason() ) );
1405 - } elseif ( $wgUser->isAnon() && $this->formtype != 'preview' ) {
1406 - $wgOut->wrapWikiMsg( "<div id=\"mw-anon-edit-warning\">\n$1</div>", 'anoneditwarning' );
 1405+ } elseif ( $wgUser->isAnon() ) {
 1406+ if ( $this->formtype != 'preview' ) {
 1407+ $wgOut->wrapWikiMsg( "<div id=\"mw-anon-edit-warning\">\n$1</div>", 'anoneditwarning' );
 1408+ } else {
 1409+ $wgOut->wrapWikiMsg( "<div id=\"mw-anon-preview-warning\">\n$1</div>", 'anonpreviewwarning' );
 1410+ }
14071411 } else {
14081412 if ( $this->isCssJsSubpage ) {
14091413 # Check the skin exists
Index: trunk/phase3/languages/messages/MessagesEn.php
@@ -1,3 +1,4 @@
 2+
23 <?php
34 /**
45 * This is the default English localisation file
@@ -1190,6 +1191,7 @@
11911192 'showdiff' => 'Show changes',
11921193 'anoneditwarning' => "'''Warning:''' You are not logged in.
11931194 Your IP address will be recorded in this page's edit history.",
 1195+'anonpreviewwarning' => "''You are not logged in. Saving will record your IP address in this page's edit history.''",
11941196 'missingsummary' => "'''Reminder:''' You have not provided an edit summary.
11951197 If you click Save again, your edit will be saved without one.",
11961198 'missingcommenttext' => 'Please enter a comment below.',
Index: trunk/phase3/RELEASE-NOTES
@@ -67,6 +67,8 @@
6868 * (bug 22991) wgUserGroups JavaScript variable now reports * group for
6969 anonymous users instead of null.
7070 * (bug 22627) Remove PHP notice when deleting a page only hidden users edited.
 71+* (bug 21520) Anonymous previews now also gives a warning about not being
 72+logged in (anonpreviewwarning).
7173
7274 == API changes in 1.17 ==
7375 * (bug 22738) Allow filtering by action type on query=logevent

Follow-up revisions

RevisionCommit summaryAuthorDate
r64379Follow-up r64367: Add new message to maintenance scriptraymond06:55, 30 March 2010

Status & tagging log