3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the Revised BSD License.
6 This program is distributed in the hope that it will be useful,
7 but WITHOUT ANY WARRANTY; without even the implied warranty of
8 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9 Revised BSD License for more details.
11 Copyright 2004-2009 iDB Support - http://idb.berlios.de/
12 Copyright 2004-2009 Game Maker 2k - http://gamemaker2k.org/
14 $FileInfo: admin.php - Last Update: 8/5/2009 SVN 291 - Author: cooldude2k $
16 if(@ini_get("register_globals")) {
17 require_once('inc/misc/killglobals.php'); }
18 require('preindex.php');
19 $usefileext = $Settings['file_ext'];
20 if($ext=="noext"||$ext=="no ext"||$ext=="no+ext") { $usefileext = ""; }
21 $filewpath = $exfile['admin'].$usefileext.$_SERVER['PATH_INFO'];
24 <title> <?php echo $Settings['board_name'].$idbpowertitle; ?> </title>
28 $_SESSION['ViewingPage'] = url_maker($exfile['index'],$Settings['file_ext'],"act=view",$Settings['qstr'],$Settings['qsep'],$prexqstr['index'],$exqstr['index']);
29 $_SESSION['PreViewingTitle'] = "Viewing";
30 $_SESSION['ViewingTitle'] = "Board index";
31 if(!isset($_GET['subact'])) { $_GET['subact'] = null; }
32 if(!isset($_POST['subact'])) { $_POST['subact'] = null; }
33 require($SettDir['inc'].'navbar.php');
34 if($_SESSION['UserGroup']==$Settings['GuestGroup']||$GroupInfo['HasAdminCP']=="no") {
35 redirect("location",$basedir.url_maker($exfile['index'],$Settings['file_ext'],"act=view",$Settings['qstr'],$Settings['qsep'],$prexqstr['index'],$exqstr['index'],false));
36 ob_clean(); @header("Content-Type: text/plain; charset=".$Settings['charset']);
37 gzip_page($Settings['use_gzip'],$GZipEncode['Type']); @mysql_close(); die(); }
38 if($_GET['act']==null) {
39 $_GET['act']="view"; }
40 if($_GET['act']=="view"&&$GroupInfo['ViewDBInfo']!="yes") {
41 $_GET['act']="view"; }
42 if($_GET['act']=="vercheck"&&$GroupInfo['ViewDBInfo']=="yes") {
43 @header("Location: ".$VerCheckURL."&bid=".$Settings['bid']); }
44 if($_GET['act']=="view"||
45 $_GET['act']=="settings"||
46 $_GET['act']=="mysql"||
47 $_GET['act']=="info"||
48 $_GET['act']=="delsessions")
49 { require($SettDir['admin'].'main.php'); }
50 if($_GET['act']=="addforum"||
51 $_GET['act']=="editforum"||
52 $_GET['act']=="deleteforum"||
53 $_GET['act']=="fpermissions")
54 { require($SettDir['admin'].'forums.php'); }
55 if($_GET['act']=="addcategory"||
56 $_GET['act']=="editcategory"||
57 $_GET['act']=="deletecategory"||
58 $_GET['act']=="cpermissions")
59 { require($SettDir['admin'].'categories.php'); }
60 require($SettDir['inc'].'endpage.php');
61 if(!isset($admincptitle)) { $admincptitle = null; }
66 if($admincptitle==null) {
67 change_title($Settings['board_name']." ".$ThemeSet['TitleDivider']." Admin CP",$Settings['use_gzip'],$GZipEncode['Type']); }
68 if($admincptitle!=null) {
69 change_title($Settings['board_name'].$admincptitle,$Settings['use_gzip'],$GZipEncode['Type']); }