From: moodler
Date: Tue, 8 Apr 2003 14:09:24 +0000 (+0000)
Subject: Use "modified" date of posts when displaying them, not the "created" date.
X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=d62413e869990ddf33ea13a8a731de62ae45a6bf;p=moodle.git
Use "modified" date of posts when displaying them, not the "created" date.
---
diff --git a/mod/forum/lib.php b/mod/forum/lib.php
index ddf1ed064d..c2703e69ff 100644
--- a/mod/forum/lib.php
+++ b/mod/forum/lib.php
@@ -189,7 +189,7 @@ function forum_cron () {
$by->name = "$userfrom->firstname $userfrom->lastname";
- $by->date = userdate($post->created, "", $userto->timezone);
+ $by->date = userdate($post->modified, "", $userto->timezone);
$strbynameondate = get_string("bynameondate", "forum", $by);
$strforums = get_string("forums", "forum");
@@ -752,7 +752,7 @@ function forum_make_mail_post(&$post, $user, $touser, $course,
$output .= "$post->subject
";
$output .= "";
$by->name = "wwwroot/user/view.php?id=$user->id&course=$course->id\">$user->firstname $user->lastname";
- $by->date = userdate($post->created, "", $touser->timezone);
+ $by->date = userdate($post->modified, "", $touser->timezone);
$output .= get_string("bynameondate", "forum", $by);
$output .= "
";
$output .= "cellcontent2\" WIDTH=10>";
@@ -828,7 +828,7 @@ function forum_print_post(&$post, $courseid, $ownpost=false, $reply=false, $link
echo "$post->subject ";
echo "";
$by->name = "wwwroot/user/view.php?id=$post->userid&course=$courseid\">$post->firstname $post->lastname";
- $by->date = userdate($post->created);
+ $by->date = userdate($post->modified);
print_string("bynameondate", "forum", $by);
echo " |
";
echo "cellcontent2\" CLASS=\"forumpostside\" WIDTH=10>";
@@ -930,7 +930,7 @@ function forum_print_post_header(&$post, $courseid, $ownpost=false, $reply=false
echo "$post->subject ";
echo "";
$by->name = "wwwroot/user/view.php?id=$post->userid&course=$courseid\">$post->firstname $post->lastname";
- $by->date = userdate($post->created);
+ $by->date = userdate($post->modified);
print_string("bynameondate", "forum", $by);
echo " | ";
@@ -1620,7 +1620,7 @@ function forum_print_posts_threaded($parent, $course, $depth, $assessed, $reply)
echo "
";
} else {
$by->name = "$post->firstname $post->lastname";
- $by->date = userdate($post->created);
+ $by->date = userdate($post->modified);
echo "discussion&parent=$post->id\">$post->subject ";
print_string("bynameondate", "forum", $by);
echo "
";