From: moodler Date: Sat, 26 Oct 2002 03:37:06 +0000 (+0000) Subject: Better formatting for the link X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=67f0b4ccb05940c5962eb6e54d56bf4eca8aa77b;p=moodle.git Better formatting for the link --- diff --git a/mod/forum/lib.php b/mod/forum/lib.php index 64acaf71e9..1e8cd049f5 100644 --- a/mod/forum/lib.php +++ b/mod/forum/lib.php @@ -600,9 +600,9 @@ function forum_print_post(&$post, $courseid, $ownpost=false, $reply=false, $link // Print shortened version echo format_text(forum_shorten_post($post->message), $post->format); $numwords = count_words(strip_tags($post->message)); - echo "wwwroot/mod/forum/discuss.php?d=$post->discussion\">"; + echo "

wwwroot/mod/forum/discuss.php?d=$post->discussion\">"; echo get_string("readtherest", "forum"); - echo " (".get_string("numwords", "", $numwords).")..."; + echo " (".get_string("numwords", "", $numwords).")...

"; } else { // Print whole message echo format_text($post->message, $post->format); @@ -736,7 +736,7 @@ function forum_shorten_post($message) { default: if (!$tag) { if ($stopzone) { - if ($char == " " or $char == ".") { + if ($char == ".") { $truncate = $i+1; break 2; } @@ -756,7 +756,7 @@ function forum_shorten_post($message) { $truncate = $i; } - return substr($message, 0, $truncate)."
"; + return substr($message, 0, $truncate); }