(bug 21520) Anonymous previews now also give a warning about not being

logged in (anonpreviewwarning).
This commit is contained in:
Platonides 2010-03-29 22:44:59 +00:00
parent 55234801e1
commit 318e4fa4ed
3 changed files with 10 additions and 2 deletions

View file

@ -67,6 +67,8 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
* (bug 22991) wgUserGroups JavaScript variable now reports * group for
anonymous users instead of null.
* (bug 22627) Remove PHP notice when deleting a page only hidden users edited.
* (bug 21520) Anonymous previews now also gives a warning about not being
logged in (anonpreviewwarning).
== API changes in 1.17 ==
* (bug 22738) Allow filtering by action type on query=logevent

View file

@ -1401,8 +1401,12 @@ HTML
if ( wfReadOnly() ) {
$wgOut->wrapWikiMsg( "<div id=\"mw-read-only-warning\">\n$1\n</div>", array( 'readonlywarning', wfReadOnlyReason() ) );
} elseif ( $wgUser->isAnon() && $this->formtype != 'preview' ) {
$wgOut->wrapWikiMsg( "<div id=\"mw-anon-edit-warning\">\n$1</div>", 'anoneditwarning' );
} elseif ( $wgUser->isAnon() ) {
if ( $this->formtype != 'preview' ) {
$wgOut->wrapWikiMsg( "<div id=\"mw-anon-edit-warning\">\n$1</div>", 'anoneditwarning' );
} else {
$wgOut->wrapWikiMsg( "<div id=\"mw-anon-preview-warning\">\n$1</div>", 'anonpreviewwarning' );
}
} else {
if ( $this->isCssJsSubpage ) {
# Check the skin exists

View file

@ -1,3 +1,4 @@
<?php
/**
* This is the default English localisation file
@ -1190,6 +1191,7 @@ You may have already successfully changed your password or requested a new tempo
'showdiff' => 'Show changes',
'anoneditwarning' => "'''Warning:''' You are not logged in.
Your IP address will be recorded in this page's edit history.",
'anonpreviewwarning' => "''You are not logged in. Saving will record your IP address in this page's edit history.''",
'missingsummary' => "'''Reminder:''' You have not provided an edit summary.
If you click Save again, your edit will be saved without one.",
'missingcommenttext' => 'Please enter a comment below.',