r55531 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r55530‎ | r55531 | r55532 >
Date:17:48, 23 August 2009
Author:purodha
Status:ok (Comments)
Tags:
Comment:
Split date, and time, in Mediawiki:enotif_body, and show localized special page name in generated e-mail.
Modified paths:
  • /trunk/phase3/includes/UserMailer.php (modified) (history)
  • /trunk/phase3/languages/messages/MessagesEn.php (modified) (history)
  • /trunk/phase3/languages/messages/MessagesQqq.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/UserMailer.php
@@ -582,8 +582,13 @@
583583 # $PAGEEDITDATE is the time and date of the page change
584584 # expressed in terms of individual local time of the notification
585585 # recipient, i.e. watching user
586 - $body = str_replace('$PAGEEDITDATE',
587 - $wgContLang->timeanddate( $this->timestamp, true, false, $timecorrection ),
 586+ $body = str_replace(
 587+ array( '$PAGEEDITDATEANDTIME',
 588+ '$PAGEEDITDATE',
 589+ '$PAGEEDITTIME' ),
 590+ array( $wgContLang->timeanddate( $this->timestamp, true, false, $timecorrection ),
 591+ $wgContLang->date( $this->timestamp, true, false, $timecorrection ),
 592+ $wgContLang->time( $this->timestamp, true, false, $timecorrection ) ),
588593 $body);
589594
590595 return UserMailer::send($to, $this->from, $this->subject, $body, $this->replyto);
Index: trunk/phase3/languages/messages/MessagesQqq.php
@@ -1976,8 +1976,13 @@
19771977 'deleted' => '{{Identical|Deleted}}',
19781978 'enotif_subject' => '$CHANGEDORCREATED can be one of {{msg|changed}} and {{msg|created}}.',
19791979 'enotif_rev_info' => 'Substituted as $REVINFO in {{msg-mw|enotif body|notext=1}}',
1980 -'enotif_body' => '$CHANGEDORCREATED can be one of {{msg-mw|changed}} and {{msg-mw|created}}.',
 1980+'enotif_body' => '$CHANGEDORCREATED can be one of {{msg-mw|changed}} and {{msg-mw|created}}.
19811981
 1982+$PAGEEDITDATEANDTIME is the date and time of the edit, alternatively
 1983+$PAGEEDITDATE is the date of the edit, and
 1984+$PAGEEDITTIME is the time of the edit.
 1985+',
 1986+
19821987 # Delete
19831988 'confirm' => 'Submit button text for protection confirmation
19841989
Index: trunk/phase3/languages/messages/MessagesEn.php
@@ -2594,7 +2594,7 @@
25952595 'enotif_body' => 'Dear $WATCHINGUSERNAME,
25962596
25972597
2598 -The {{SITENAME}} page $PAGETITLE has been $CHANGEDORCREATED on $PAGEEDITDATE by $PAGEEDITOR. $REVINFO
 2598+The {{SITENAME}} page $PAGETITLE has been $CHANGEDORCREATED on $PAGEEDITDATEANDTIME by $PAGEEDITOR. $REVINFO
25992599
26002600 $NEWPAGE
26012601
@@ -2611,7 +2611,7 @@
26122612
26132613 --
26142614 To change your watchlist settings, visit
2615 -{{fullurl:{{ns:special}}:Watchlist/edit}}
 2615+{{fullurl:{{#special:Watchlist}}/edit}}
26162616
26172617 Feedback and further assistance:
26182618 {{fullurl:{{MediaWiki:Helppage}}}}',

Comments

#Comment by Brion VIBBER (talk | contribs)   18:47, 10 September 2009

This isn't exactly back-compat but should be good enough.

Status & tagging log