From: martin <martin> Date: Mon, 29 Jul 2002 09:17:14 +0000 (+0000) Subject: Minor forum formatting tweaks X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=77305fe6eb7469ad30dcf63135c3ff0ee6d738f6;p=moodle.git Minor forum formatting tweaks --- diff --git a/mod/forum/lib.php b/mod/forum/lib.php index e8ff32a769..543054fd72 100644 --- a/mod/forum/lib.php +++ b/mod/forum/lib.php @@ -157,6 +157,12 @@ function print_forum_latest_topics($forum_id=0, $forum_numtopics=5, $forum_style } } + if (user_can_post_discussion($forum)) { + echo "<P ALIGN=right>"; + echo "<A HREF=\"$CFG->wwwroot/mod/discuss/post.php?forum=$forum->id\">Add a new topic...</A>"; + echo "</P>"; + } + if (! $topics = get_all_topics($forum->id, $forum_sort) ) { echo "<P ALIGN=CENTER><B>There are no discussion topics yet in this forum.</B></P>"; @@ -193,12 +199,6 @@ function print_forum_latest_topics($forum_id=0, $forum_numtopics=5, $forum_style } } } - if (user_can_post_discussion($forum)) { - echo "<P ALIGN=right>"; - echo "<A HREF=\"$CFG->wwwroot/mod/discuss/post.php?forum=$forum->id\">Add a new topic...</A>"; - echo "</P>"; - } - } diff --git a/mod/forum/view.php b/mod/forum/view.php index 7049132f6f..7b96547146 100644 --- a/mod/forum/view.php +++ b/mod/forum/view.php @@ -75,7 +75,7 @@ case "eachuser": echo "<P ALIGN=CENTER>"; if (user_can_post_discussion($forum)) { - echo "This forum allows one discussion topic to be posted per person. Click here to <A HREF=\"../discuss/post.php?forum=$forum->id\">post your topic</A>."; + echo "This forum allows one discussion topic to be posted per person."; } else { echo " "; }