Index: openacs.org-dev/packages/forums/www/message-post.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs.org-dev/packages/forums/www/message-post.tcl,v diff -u -r1.4 -r1.5 --- openacs.org-dev/packages/forums/www/message-post.tcl 12 Aug 2002 20:18:26 -0000 1.4 +++ openacs.org-dev/packages/forums/www/message-post.tcl 12 Aug 2002 20:22:37 -0000 1.5 @@ -19,6 +19,18 @@ set user_id [ad_verify_and_get_user_id] +if {![empty_string_p $parent_id]} { + # get the parent message information + forum::message::get -message_id $parent_id -array parent_message + set forum_id $parent_message(forum_id) + set subject "Re: $parent_message(subject)" + +} + +forum::security::require_post_forum -forum_id $forum_id + +forum::get -forum_id $forum_id -array forum + # get the colors from the params set table_border_color [parameter::get -parameter table_border_color] set table_bgcolor [parameter::get -parameter table_bgcolor] @@ -47,7 +59,7 @@ } {subscribe_p:text(hidden)} } -validate { content - {[expr {[string equal [set error_message [ad_html_security_check $content]] "" ]}]} $error_message + {[expr {[string equal [set error_message [ad_html_security_check $content]] "" ]}]} $error_message} } -new_data { forum::get -forum_id $forum_id -array forum @@ -132,18 +144,6 @@ #set message_id [db_nextval acs_object_id_seq] set subject "" -if {![empty_string_p $parent_id]} { - # get the parent message information - forum::message::get -message_id $parent_id -array parent_message - set forum_id $parent_message(forum_id) - set subject "Re: $parent_message(subject)" - -} - -forum::security::require_post_forum -forum_id $forum_id - -forum::get -forum_id $forum_id -array forum - # Prepare the other data set context_bar [list [list "./forum-view?forum_id=$forum_id" "$forum(name)"]]