| |
1 |
1 |
ad_page_contract { |
| |
2 |
2 |
|
| |
3 |
3 |
Edit a Forum |
| |
4 |
4 |
|
| |
5 |
5 |
@author Ben Adida (ben@openforce.net) |
| |
6 |
6 |
@creation-date 2002-05-25 |
| |
7 |
7 |
@cvs-id $Id$ |
| |
8 |
8 |
|
| |
9 |
9 |
} { |
| |
10 |
|
forum_id:object_type(forums_forum) |
| |
|
10 |
forum_id:object_type(forums_forum),notnull |
| |
11 |
11 |
{return_url:localurl "."} |
| |
12 |
12 |
} |
| |
13 |
13 |
|
| |
14 |
14 |
# Select the info |
| |
15 |
15 |
set package_id [ad_conn package_id] |
| |
16 |
16 |
try { |
| |
17 |
17 |
forum::get -forum_id $forum_id -array forum |
| |
18 |
18 |
} trap {NOT_FOUND} {} { |
| |
19 |
19 |
ns_returnnotfound |
| |
20 |
20 |
ad_script_abort |
| |
21 |
21 |
} |
| |
22 |
22 |
|
| |
23 |
23 |
# Proper scoping? |
| |
24 |
24 |
if {$package_id != $forum(package_id)} { |
| |
25 |
25 |
ns_log Error "Forum Administration: Bad Scoping of Forum #$forum_id in Forum Editing" |
| |
26 |
26 |
ad_returnredirect "./" |
| |
27 |
27 |
ad_script_abort |
| |
28 |
28 |
} |
| |
29 |
29 |
|
| |
30 |
30 |
set context [list [_ forums.Edit_forum]] |