Index: openacs-4/packages/dotlrn/www/one-community-configure-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/www/one-community-configure-2.tcl,v diff -u -r1.4 -r1.5 --- openacs-4/packages/dotlrn/www/one-community-configure-2.tcl 7 Nov 2001 15:34:08 -0000 1.4 +++ openacs-4/packages/dotlrn/www/one-community-configure-2.tcl 9 Nov 2001 02:42:26 -0000 1.5 @@ -11,28 +11,28 @@ set form [ns_getform] -set portal_id [ns_set get $form portal_id] +set page_id [ns_set get $form portal_id] -# Check that this is a community type -if {[ad_parameter community_level_p] != 1} { - ns_returnredirect "./" +# Check if this is a community type level thing +if {[ad_parameter community_type_level_p] == 1} { + ad_returnredirect "one-community-type" return } -set user_id [ad_conn user_id] +# Check if this is a community level thing +if {[ad_parameter community_level_p] == 1} { + ad_returnredirect "one-community" + return +} -# What community type are we at? -set community_id [dotlrn_community::get_community_id] +# Make sure user is logged in +set user_id [ad_maybe_redirect_for_registration] -# Check that this user is a member -if {![dotlrn_community::member_p $community_id $user_id]} { - set context_bar [list "Not a member"] +# If there is no page_id, this user is either a guest or something else +if {![empty_string_p $page_id]} { + portal::configure_dispatch $page_id $form +} - ad_return_template one-community-not-member - return -} else { +ad_returnredirect "one-community-configure" - portal::configure_dispatch $portal_id $form - ns_returnredirect "one-community-configure" -}