1<?php
2/***************************************************************************
3* copyright            : (C) 2001-2003 Advanced Internet Designs Inc.
4* email                : forum@prohost.org
5* $Id: root_index.php.t 21069 2010-03-25 22:47:48Z Caeies $
6*
7* This program is free software; you can redistribute it and/or modify it
8* under the terms of the GNU General Public License as published by the
9* Free Software Foundation; either version 2 of the License, or
10* (at your option) any later version.
11***************************************************************************/
12
13	require('./GLOBALS.php');
14
15	/* before we go on, we need to do some very basic activation checks */
16	if (!($FUD_OPT_1 & 1)) {
17		fud_phpgw();
18		fud_use('errmsg.inc');
19		exit($DISABLED_REASON . __fud_ecore_adm_login_msg);
20	}
21
22	if (isset($_GET['t'])) {
23		$t = $_GET['t'];
24	} else if (isset($_POST['t'])) {
25		$t = $_POST['t'];
26	} else {
27		$t = 'index';
28	}
29
30	if ($t == 'rview') {
31		if (isset($_GET['th']) || isset($_GET['goto'])) {
32			$t = $_GET['t'] = d_thread_view;
33		} else if (isset($_GET['frm_id'])) {
34			$t = $_GET['t'] = t_thread_view;
35		} else {
36			$t = $_GET['t'] = 'index';
37		}
38	} else if (preg_match('/[^A-Za-z0-9_]/', $t)) {
39		$t = 'index';
40	}
41
42	if ($FUD_OPT_2 & 16384 && $t != 'getfile') {
43		ob_start(array('ob_gzhandler', (int)$PHP_COMPRESSION_LEVEL));
44	}
45
46	fud_phpgw($t, 0);
47
48/*{PRE_HTML_PHP}*/
49/*{POST_HTML_PHP}*/
50
51	fud_use('err.inc');
52
53	define('__index_page_start__', true);
54	if (isset($GLOBALS['fud_phpgw_hdr'])) {
55		$GLOBALS['fud_phpgw_hdr'] = str_replace('fudforum/lib.js" type="text/javascript"></script>', 'fudforum/lib.js" type="text/javascript"></script><link href="'.$GLOBALS['WWW_ROOT'].fud_theme.'/forum.css" type="text/css" rel="StyleSheet" /></HEAD>', $GLOBALS['fud_phpgw_hdr']);
56	}
57	require($WWW_ROOT_DISK . fud_theme . $t . '.php');
58?>
59