Index: includes/EditPage.php
===================================================================
RCS file: /cvsroot/wikipedia/phase3/includes/EditPage.php,v
retrieving revision 1.258
diff -u -r1.258 EditPage.php
--- includes/EditPage.php 23 Jan 2006 20:44:56 -0000 1.258
+++ includes/EditPage.php 4 Feb 2006 19:11:37 -0000
@@ -24,6 +24,7 @@
var $firsttime;
var $lastDelete;
var $mTokenOk = true;
+ var $commentMissingText = false;
# Form values
var $save = false, $preview = false, $diff = false;
@@ -610,6 +611,10 @@
wfProfileIn( "$fname-sectionanchor" );
$sectionanchor = '';
if( $this->section == 'new' ) {
+ if ( $this->textbox1 == '' ) {
+ $this->commentMissingText = true;
+ return true;
+ }
if( $this->summary != '' ) {
$sectionanchor = $this->sectionAnchor( $this->summary );
}
@@ -707,6 +712,11 @@
$s = wfMsg( 'editing', $this->mTitle->getPrefixedText() );
}
$wgOut->setPageTitle( $s );
+
+ if ( $this->commentMissingText ) {
+ $wgOut->addWikiText( wfMsg( 'commentmissingtext' ) );
+ }
+
if ( !$this->checkUnicodeCompliantBrowser() ) {
$wgOut->addWikiText( wfMsg( 'nonunicodebrowser') );
}
--- languages/Messages.php.1.1 2006-02-02 14:40:14.000000000 -0500
+++ languages/Messages.php 2006-02-04 11:27:28.000000000 -0500
@@ -450,6 +450,7 @@
'preview' => 'Preview',
'showpreview' => 'Show preview',
'showdiff' => 'Show changes',
+'commentmissingtext' => 'Please enter a comment below.',
'blockedtitle' => 'User is blocked',
'blockedtext' => 'Your user name or IP address has been blocked by $1.
The reason given is this:
\'\'$2\'\'
You may contact $1 or one of the other