OSDN Git Service

Small change. :P
[idb/iDB.git.git] / inc / misc / setcheck.php
1 <?php
2 /*
3     This program is free software; you can redistribute it and/or modify
4     it under the terms of the Revised BSD License.
5
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.
10
11     Copyright 2004-2008 Cool Dude 2k - http://idb.berlios.de/
12     Copyright 2004-2008 Game Maker 2k - http://intdb.sourceforge.net/
13
14     $FileInfo: setcheck.php - Last Update: 12/09/2008 SVN 207 - Author: cooldude2k $
15 */
16 $File3Name = basename($_SERVER['SCRIPT_NAME']);
17 if ($File3Name=="setcheck.php"||$File3Name=="/setcheck.php") {
18         require('index.php');
19         exit(); }
20 if(!isset($_GET['debug'])) { $_GET['debug'] = false; }
21 if(!isset($GZipEncode)) { $GZipEncode = array("Type" => "none"); }
22 if(!is_array($GZipEncode)) { $GZipEncode = array("Type" => "none"); }
23 if(!isset($preact)) { $preact = null; }
24 if(!isset($Settings['hash_type'])) { $Settings['hash_type'] = null; }
25 if(!isset($Error)) { $Error = null; }
26 if(!isset($passright)) { $passright = null; }
27 if(!isset($Settings['enable_pathinfo'])) {
28   $Settings['enable_pathinfo'] = "off";  }
29 if($Settings['enable_pathinfo']!="on"&&
30         $Settings['enable_pathinfo']!="off") {
31   $Settings['enable_pathinfo'] = "off";  }
32 $Settings['sessionid_in_urls'] = "off";
33 if(!isset($Settings['sessionid_in_urls'])) {
34   $Settings['sessionid_in_urls'] = "off";  }
35 if($Settings['sessionid_in_urls']!="on"&&
36         $Settings['sessionid_in_urls']!="off") {
37   $Settings['sessionid_in_urls'] = "off";  }
38 if(!isset($Settings['use_captcha'])) {
39         $Settings['use_captcha'] = "on"; }
40 if(isset($Settings['use_captcha'])) {
41         if($Settings['use_captcha']!="on"&&
42                 $Settings['use_captcha']!="off") {
43         $Settings['use_captcha'] = "on"; } }
44 if(!isset($Settings['captcha_guest'])) {
45         $Settings['captcha_guest'] = "on"; }
46 if(isset($Settings['captcha_guest'])) {
47         if($Settings['captcha_guest']!="on"&&
48                 $Settings['captcha_guest']!="off") {
49         $Settings['captcha_guest'] = "on"; } }
50 if(!isset($Settings['captcha_clean'])) {
51         $Settings['captcha_clean'] = "off"; }
52 if(isset($Settings['captcha_clean'])) {
53         if($Settings['captcha_clean']!="on"&&
54                 $Settings['captcha_clean']!="off") {
55         $Settings['captcha_clean'] = "on"; } }
56 $sidurls = $Settings['sessionid_in_urls'];
57 if(!isset($Settings['board_offline'])) {
58   $Settings['board_offline'] = "off";  }
59 if($Settings['board_offline']!="on"&&
60         $Settings['board_offline']!="off") {
61   $Settings['board_offline'] = "off";  }
62 $oldusername = null; $oldtopicname = null; $ext = null;
63 if($Settings['DefaultTheme']==null) {
64         $Settings['DefaultTheme'] = "iDB"; }
65 if($Settings['DefaultTimeZone']==null) {
66         $Settings['DefaultTimeZone'] = SeverOffSet(null); }
67 if($Settings['DefaultDST']!="on"&&
68         $Settings['DefaultDST']!="off") { 
69         $Settings['DefaultDST'] = "off"; }
70 if(!isset($Settings['use_captcha'])) {
71         $Settings['use_captcha'] = "off"; }
72 if($Settings['use_captcha']!="on"&&
73         $Settings['use_captcha']!="off") { 
74         $Settings['use_captcha'] = "off"; }
75 if(!isset($Settings['captcha_clean'])) {
76         $Settings['captcha_clean'] = "off"; }
77 if($Settings['captcha_clean']!="on"&&
78         $Settings['captcha_clean']!="off") { 
79         $Settings['captcha_clean'] = "off"; }
80 if($Settings['enable_rss']!="on"&&
81         $Settings['enable_rss']!="on") { 
82         $Settings['enable_rss'] = "off"; }
83 if($Settings['enable_rss']=="on") { 
84     $Settings['enable_rss'] = "on"; }
85 if (file_exists("themes/iDB/settings.php")) {
86         $FallBack['DefaultTheme'] = "iDB"; }
87 if (!file_exists("themes/iDB/settings.php")) {
88         $FallBack['DefaultTheme'] = "Gray"; }
89 if($Settings['DefaultTheme']!=null) {
90 if (file_exists("themes/".$Settings['DefaultTheme']."/settings.php")) {
91 /* The file Skin Exists */ }
92 else { $Settings['DefaultTheme']=$FallBack['DefaultTheme'];
93 /* The file Skin Dose Not Exists */ } }
94 if($Settings['TestReferer']!="on"&&
95         $Settings['TestReferer']!="off") {
96         $Settings['TestReferer'] = "off"; }
97 if($Settings['charset']==null) {
98         $Settings['charset'] = "iso-8859-15"; }
99 if($Settings['qstr']==null) {
100         $Settings['qstr'] = "&"; }
101 if($Settings['qsep']==null) {
102         $Settings['qsep'] = "="; }
103 if($Settings['qsep']=="#"||
104         $Settings['qstr']=="#") {
105         $Settings['qstr'] = "&";
106         $Settings['qsep'] = "="; }
107 if($Settings['qsep']==$Settings['qstr']) {
108         $Settings['qstr'] = "&";
109         $Settings['qsep'] = "="; }
110 if($Settings['qstr']=="/"||
111         $Settings['qstr']=="&") {
112         $Settings['qsep'] = "="; }
113 if($Settings['qstr']!="&"&&
114         $Settings['qstr']!="/") {
115 @qstring($Settings['qstr'],$Settings['qsep']);
116 if(!isset($_GET['page'])) { $_GET['page'] = null; }
117 if(!isset($_GET['act'])) { $_GET['act'] = null; }
118 if(!isset($_POST['act'])) { $_POST['act'] = null; }
119 if(!isset($_GET['id'])) { $_GET['id'] = null; } 
120 if(!isset($_GET['debug'])) { $_GET['debug'] = "false"; }
121 if(!isset($_GET['post'])) { $_GET['post'] = null; }
122 if(!isset($_POST['License'])) { $_POST['License'] = null; } }
123 if(!isset($Settings['enable_https'])) {
124   $Settings['enable_https'] = "off";  }
125 if($Settings['enable_https']!="on"&&
126         $Settings['enable_https']!="off") {
127   $Settings['enable_https'] = "off";  }
128 if(!isset($Settings['file_ext'])||
129         $Settings['file_ext']==null) {
130         $Settings['file_ext'] = ".php"; }
131 if(!isset($Settings['rss_ext'])||
132         $Settings['rss_ext']==null) {
133         $Settings['rss_ext'] = ".php"; }
134 if(!isset($Settings['js_ext'])||
135         $Settings['js_ext']==null) {
136         $Settings['js_ext'] = ".js"; }
137 if(!isset($Settings['add_power_by'])) {
138   $Settings['add_power_by'] = "off";  }
139 if($Settings['add_power_by']=="on") {
140 $idbpowertitle = " (Powered by ".$iDB.")";
141 $itbpowertitle = " (Powered by ".$iTB.")"; }
142 if($Settings['add_power_by']!="on") {
143 $idbpowertitle = null;
144 $itbpowertitle = null; }
145 if($Settings['GuestGroup']==null) {
146         $Settings['GuestGroup'] = "Guest"; }
147 if($Settings['MemberGroup']==null) {
148         $Settings['MemberGroup'] = "Member"; }
149 if($Settings['ValidateGroup']==null&&
150         $Settings['AdminValidate']=="on") {
151 $Settings['ValidateGroup'] = "Validate"; }
152 if($Settings['html_type']=="html4") { 
153         $Settings['html_type'] = "html10"; }
154 /*if($_GET['debug']!="off"||$_GET['debug']=="on") {
155         output_add_rewrite_var("amp;debug",$_GET['debug']); }*/
156 if (!isset($_GET['action'])) { $_GET['action'] = null; }
157 if (!isset($_GET['activity'])) { $_GET['activity'] = null; }
158 if (!isset($_GET['function'])) { $_GET['function'] = null; }
159 if (!isset($_GET['mode'])) { $_GET['mode'] = null; }
160 if (!isset($_GET['show'])) { $_GET['show'] = null; }
161 if (!isset($_GET['do'])) { $_GET['do'] = null; }
162 if ($_GET['act']==null&&$_GET['action']!=null) { $_GET['act']=$_GET['action']; }
163 if ($_GET['act']==null&&$_GET['activity']!=null) { $_GET['act']=$_GET['activity']; }
164 if ($_GET['act']==null&&$_GET['function']!=null) { $_GET['act']=$_GET['function']; }
165 if ($_GET['act']==null&&$_GET['mode']!=null) { $_GET['act']=$_GET['mode']; }
166 if ($_GET['act']==null&&$_GET['show']!=null) { $_GET['act']=$_GET['show']; }
167 if ($_GET['act']==null&&$_GET['do']!=null) { $_GET['act']=$_GET['do']; }
168 if ($_GET['act']=="idx"||$_GET['act']=="View") { $_GET['act']="view"; }
169 if ($_GET['act']=="iDBInfo") { @header('Location: http://sourceforge.net/projects/intdb/'); }
170 if ($_GET['act']=="iDBSite") { @header('Location: http://intdb.sourceforge.net/'); }
171 if ($_GET['act']=="OldiDBInfo") { @header('Location: http://developer.berlios.de/projects/idb/'); }
172 if ($_GET['act']=="OldiDBSite") { @header('Location: http://idb.berlios.de/'); }
173 if ($_GET['act']=="DF2kInfo") { @header('Location: http://developer.berlios.de/projects/df2k/'); }
174 if ($_GET['act']=="DF2kSite") { @header('Location: http://df2k.berlios.de/'); }
175 if ($_GET['act']=="GM2kSite") { @header('Location: http://upload.idb.s1.jcink.com/'); }
176 ?>