2003-07-18 21:38:51 +00:00
|
|
|
<?php
|
2003-08-13 22:08:12 +00:00
|
|
|
|
2004-02-02 23:34:39 +00:00
|
|
|
require_once('../inc/forum.inc');
|
|
|
|
require_once('../inc/util.inc');
|
|
|
|
require_once('../inc/time.inc');
|
2004-05-30 21:47:11 +00:00
|
|
|
require_once('../inc/forum_show.inc');
|
2003-07-18 21:38:51 +00:00
|
|
|
|
2004-12-27 03:42:11 +00:00
|
|
|
db_init();
|
|
|
|
|
2005-02-13 06:13:33 +00:00
|
|
|
$id = get_int("id");
|
|
|
|
$sort_style = get_str("sort", true);
|
|
|
|
$start = get_int("start", true);
|
|
|
|
if (!$start) $start = 0;
|
2003-07-18 21:38:51 +00:00
|
|
|
|
2005-02-13 06:13:33 +00:00
|
|
|
$forum = getForum($id);
|
2003-08-13 22:08:12 +00:00
|
|
|
$category = getCategory($forum->category);
|
2004-09-05 19:26:27 +00:00
|
|
|
$logged_in_user = get_logged_in_user(false);
|
|
|
|
$logged_in_user = getForumPreferences($logged_in_user);
|
2003-08-01 20:30:25 +00:00
|
|
|
|
2003-08-13 22:08:12 +00:00
|
|
|
if ($category->is_helpdesk) {
|
2004-01-19 01:12:53 +00:00
|
|
|
if (!$sort_style) {
|
2004-09-04 23:37:49 +00:00
|
|
|
$sort_style = getSortStyle($logged_in_user,"faq");
|
2004-01-19 01:12:53 +00:00
|
|
|
} else {
|
2004-09-04 23:37:49 +00:00
|
|
|
setSortStyle($logged_in_user,"faq",$sort_style);
|
2004-01-19 01:12:53 +00:00
|
|
|
}
|
2003-12-21 05:55:48 +00:00
|
|
|
if (!$sort_style) $sort_style = 'activity';
|
2004-01-19 01:12:53 +00:00
|
|
|
page_head('Help Desk');
|
2003-08-01 20:30:25 +00:00
|
|
|
} else {
|
2004-01-19 01:12:53 +00:00
|
|
|
if (!$sort_style) {
|
2004-09-04 23:37:49 +00:00
|
|
|
$sort_style = getSortStyle($logged_in_user,"forum");
|
2004-01-19 01:12:53 +00:00
|
|
|
} else {
|
2005-02-13 06:13:33 +00:00
|
|
|
setSortStyle($logged_in_user, "forum",$sort_style);
|
2004-01-19 01:12:53 +00:00
|
|
|
}
|
2003-12-08 07:36:43 +00:00
|
|
|
if (!$sort_style) $sort_style = 'modified-new';
|
2004-01-19 01:12:53 +00:00
|
|
|
page_head('Message boards : '.$forum->title);
|
2005-03-10 11:29:55 +00:00
|
|
|
echo "<link href=\"forum_index.php\" rel=\"up\" title=\"Forum Index\">";
|
2003-07-30 00:50:54 +00:00
|
|
|
}
|
2003-08-13 22:08:12 +00:00
|
|
|
|
|
|
|
echo "
|
2004-06-01 18:55:59 +00:00
|
|
|
<form action=forum_forum.php method=get>
|
2004-05-24 03:40:38 +00:00
|
|
|
<input type=hidden name=id value=", $forum->id, ">
|
2003-11-30 21:05:57 +00:00
|
|
|
<table width=100% cellspacing=0 cellpadding=0>
|
2004-05-24 03:40:38 +00:00
|
|
|
<tr valign=bottom>
|
|
|
|
<td align=left style=\"border:0px\">
|
2003-08-13 22:08:12 +00:00
|
|
|
";
|
|
|
|
|
|
|
|
show_forum_title($forum, NULL, $category->is_helpdesk);
|
|
|
|
|
2005-02-13 06:13:33 +00:00
|
|
|
echo "<p>\n<a href=forum_post.php?id=$id>";
|
2003-08-13 22:08:12 +00:00
|
|
|
|
|
|
|
if ($category->is_helpdesk) {
|
2003-12-09 06:46:50 +00:00
|
|
|
echo "Submit a question or problem";
|
2003-08-13 22:08:12 +00:00
|
|
|
} else {
|
2003-11-30 21:05:57 +00:00
|
|
|
echo "Create a new thread";
|
2003-08-13 22:08:12 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
echo "</a>\n</p>\n</td>";
|
|
|
|
|
2003-12-08 01:19:49 +00:00
|
|
|
echo "<td align=right>";
|
|
|
|
if ($category->is_helpdesk) {
|
|
|
|
show_select_from_array("sort", $faq_sort_styles, $sort_style);
|
|
|
|
} else {
|
|
|
|
show_select_from_array("sort", $forum_sort_styles, $sort_style);
|
2003-08-13 22:08:12 +00:00
|
|
|
}
|
2003-12-08 01:19:49 +00:00
|
|
|
echo "<input type=submit value=OK></td>\n";
|
2003-08-13 22:08:12 +00:00
|
|
|
|
|
|
|
echo "</tr>\n</table>\n</form>";
|
2004-09-04 23:37:49 +00:00
|
|
|
show_forum($category, $forum, $start, $sort_style, $logged_in_user);
|
2003-07-18 21:38:51 +00:00
|
|
|
|
2003-08-15 01:01:00 +00:00
|
|
|
page_tail();
|
2003-08-13 22:08:12 +00:00
|
|
|
|
2003-11-30 21:05:57 +00:00
|
|
|
?>
|