OSDN Git Service

Yet another bug fix. <_<
authorKazuki Przyborowski <kazuki.przyborowski@gmail.com>
Mon, 14 May 2007 15:08:18 +0000 (15:08 +0000)
committerKazuki Przyborowski <kazuki.przyborowski@gmail.com>
Mon, 14 May 2007 15:08:18 +0000 (15:08 +0000)
git-svn-id: svn://svn.code.sf.net/p/intdb/svn/trunk@6 2b68903e-0b30-0410-9a39-a2e4f3c5be39

inc/filename.php
inc/misc/functions.php
mysql.php
setup/mkconfig.php
setup/setup.php
themes/iDB/info.php
themes/iDB/settings.php

index 596c1ea..13d49e0 100644 (file)
@@ -11,7 +11,7 @@
     Copyright 2004-2007 Cool Dude 2k - http://intdb.sourceforge.net/\r
     Copyright 2004-2007 Game Maker 2k - http://upload.idb.s1.jcink.com/\r
 \r
-    $FileInfo: filename.php - Last Update: 05/14/2007 SVN 5 - Author: cooldude2k $\r
+    $FileInfo: filename.php - Last Update: 05/14/2007 SVN 6 - Author: cooldude2k $\r
 */\r
 $File1Name = dirname($_SERVER['SCRIPT_NAME'])."/";\r
 $File2Name = $_SERVER['SCRIPT_NAME'];\r
@@ -45,7 +45,7 @@ function version_info($proname,$subver,$ver,$supver,$reltype,$svnver,$showsvn) {
        if($showsvn!=true&&$showsvn!=null) { $return_var .= " ".$showsvn." ".$svnver; }\r
        return $return_var; }\r
 $VER1[0] = 0; $VER1[1] = 1; $VER1[2] = 5; $VERFull[1] = $VER1[0].".".$VER1[1].".".$VER1[2];\r
-$VER2[0] = "Pre-Alpha"; $VER2[1] = "PA"; $VER2[2] = "SVN"; $SubVerN = 5; $RName = "iDB"; $SFName = "IntDB";\r
+$VER2[0] = "Pre-Alpha"; $VER2[1] = "PA"; $VER2[2] = "SVN"; $SubVerN = 6; $RName = "iDB"; $SFName = "IntDB";\r
 $SVNDay[0] = 5; $SVNDay[1] = 14; $SVNDay[2] = 2007; $SVNDay[3] = $SVNDay[0]."/".$SVNDay[1]."/".$SVNDay[2];\r
 $VerInfo['iDB_Ver'] = version_info($RName,$VER1[0],$VER1[1],$VER1[2],$VER2[1],$SubVerN,false);\r
 $VerInfo['iDB_Ver_SVN'] = version_info($RName,$VER1[0],$VER1[1],$VER1[2],$VER2[1],$SubVerN,true);\r
index a070ec5..a90b8fb 100644 (file)
@@ -11,7 +11,7 @@
     Copyright 2004-2007 Cool Dude 2k - http://intdb.sourceforge.net/\r
     Copyright 2004-2007 Game Maker 2k - http://upload.idb.s1.jcink.com/\r
 \r
-    $FileInfo: functions.php - Last Update: 05/14/2007 SVN 5 - Author: cooldude2k $\r
+    $FileInfo: functions.php - Last Update: 05/14/2007 SVN 6 - Author: cooldude2k $\r
 */\r
 $File1Name = dirname($_SERVER['SCRIPT_NAME'])."/";\r
 $File2Name = $_SERVER['SCRIPT_NAME'];\r
@@ -57,7 +57,7 @@ if (!$StatBase) { return false; }
 return true; }\r
        $Names['RS'] = "Renee Sabonis";\r
 define("_renee_", $Names['RS']);\r
-function change_title($new_title,$use_gzip,$gzip_type) {\r
+function change_title($new_title,$use_gzip="off",$gzip_type="gzip") {\r
 global $Settings;\r
 if($gzip_type!="gzip") { if($gzip_type!="deflate") { $gzip_type = "gzip"; } }\r
 $output = @ob_get_clean();\r
@@ -67,15 +67,15 @@ $SessName = @session_name();
 $output = preg_replace("/&PHPSESSID/", "&amp;PHPSESSID", $output);\r
 $qstrcode = htmlentities($Settings['qstr']);\r
 $output = str_replace($Settings['qstr'].$SessName, $qstrcode.$SessName, $output);\r
-if($use_gzip!=true) {\r
+if($use_gzip!="on") {\r
        echo $output; }\r
-if($use_gzip==true) {\r
+if($use_gzip=="on") {\r
        if($gzip_type=="gzip") {\r
        $goutput = gzencode($output); }\r
        if($gzip_type=="deflate") {\r
        $goutput = gzcompress($output); }\r
        echo $goutput; } }\r
-function fix_amp($use_gzip,$gzip_type) {\r
+function fix_amp($use_gzip="off",$gzip_type="gzip") {\r
 global $Settings;\r
 if($gzip_type!="gzip") { if($gzip_type!="deflate") { $gzip_type = "gzip"; } }\r
 $output = @ob_get_clean();\r
@@ -84,23 +84,23 @@ $SessName = @session_name();
 $output = preg_replace("/&PHPSESSID/", "&amp;PHPSESSID", $output);\r
 $qstrcode = htmlentities($Settings['qstr']);\r
 $output = str_replace($Settings['qstr'].$SessName, $qstrcode.$SessName, $output);\r
-if($use_gzip!=true) {\r
+if($use_gzip!="on") {\r
        echo $output; }\r
-if($use_gzip==true) {\r
+if($use_gzip=="on") {\r
        if($gzip_type=="gzip") {\r
        $goutput = gzencode($output); }\r
        if($gzip_type=="deflate") {\r
        $goutput = gzcompress($output); }\r
        echo $goutput; } }\r
-function gzip_page($use_gzip,$gzip_type) {\r
+function gzip_page($use_gzip="off",$gzip_type="gzip") {\r
 global $Settings;\r
 if($gzip_type!="gzip") { if($gzip_type!="deflate") { $gzip_type = "gzip"; } }\r
 $output = @ob_get_clean();\r
        $Names['RJ'] = "RenĂ© Johnson";\r
 define("_rene_", $Names['RJ']);\r
-if($use_gzip!=true) {\r
+if($use_gzip!="on") {\r
        echo $output; }\r
-if($use_gzip==true) {\r
+if($use_gzip=="on") {\r
        if($gzip_type=="gzip") {\r
        $goutput = gzencode($output); }\r
        if($gzip_type=="deflate") {\r
index c6332ca..7dc5880 100644 (file)
--- a/mysql.php
+++ b/mysql.php
@@ -11,7 +11,7 @@
     Copyright 2004-2007 Cool Dude 2k - http://intdb.sourceforge.net/
     Copyright 2004-2007 Game Maker 2k - http://upload.idb.s1.jcink.com/
 
-    $FileInfo: mysql.php - Last Update: 05/14/2007 SVN 4 - Author: cooldude2k $
+    $FileInfo: mysql.php - Last Update: 05/14/2007 SVN 6 - Author: cooldude2k $
 */
 @error_reporting(E_ALL ^ E_NOTICE);
 @ini_set('session.use_trans_sid', false);
@@ -46,20 +46,20 @@ if ($File3Name=="mysql.php"||$File3Name=="/mysql.php") {
        require($SettDir['inc'].'forbidden.php');
        exit(); }
 //error_reporting(E_ERROR);
-if($Settings['use_gzip']==true) {
+if($Settings['use_gzip']=="on") {
 if(strstr($_SERVER['HTTP_ACCEPT_ENCODING'], "gzip")) { 
        $GZipEncode['Type'] = "gzip"; } else { 
        if(strstr($_SERVER['HTTP_ACCEPT_ENCODING'], "deflate")) { 
        $GZipEncode['Type'] = "deflate"; } else { 
-               $Settings['use_gzip'] = false; $GZipEncode['Type'] = "none"; } } }
+               $Settings['use_gzip'] = "off"; $GZipEncode['Type'] = "none"; } } }
 if($Settings['use_gzip']=="gzip") {
-if(strstr($_SERVER['HTTP_ACCEPT_ENCODING'], "gzip")) { $Settings['use_gzip'] = true;
-       $GZipEncode['Type'] = "gzip"; } else { $Settings['use_gzip'] = false; } }
+if(strstr($_SERVER['HTTP_ACCEPT_ENCODING'], "gzip")) { $Settings['use_gzip'] = "on";
+       $GZipEncode['Type'] = "gzip"; } else { $Settings['use_gzip'] = "off"; } }
 if($Settings['use_gzip']=="deflate") {
-if(strstr($_SERVER['HTTP_ACCEPT_ENCODING'], "deflate")) { $Settings['use_gzip'] = true;
-       $GZipEncode['Type'] = "deflate"; } else { $Settings['use_gzip'] = false; } }
+if(strstr($_SERVER['HTTP_ACCEPT_ENCODING'], "deflate")) { $Settings['use_gzip'] = "on";
+       $GZipEncode['Type'] = "deflate"; } else { $Settings['use_gzip'] = "off"; } }
 @ob_start();
-if($Settings['use_gzip']==true) { 
+if($Settings['use_gzip']=="on") { 
 if($GZipEncode['Type']!="gzip") { if($GZipEncode['Type']!="deflate") { $GZipEncode['Type'] = "gzip"; } }
        if($GZipEncode['Type']=="gzip") {
        @header("Content-Encoding: gzip"); }
index 117eb3d..28bd37e 100644 (file)
@@ -12,7 +12,7 @@
     Copyright 2004-2007 Game Maker 2k - http://upload.idb.s1.jcink.com/
     iDB Installer made by Game Maker 2k - http://idb.berlios.net/
 
-    $FileInfo: mkconfig.php - Last Update: 05/10/2007 SVN 2 - Author: cooldude2k $
+    $FileInfo: mkconfig.php - Last Update: 05/14/2007 SVN 6 - Author: cooldude2k $
 */
 $File1Name = dirname($_SERVER['SCRIPT_NAME'])."/";
 $File2Name = $_SERVER['SCRIPT_NAME'];
@@ -125,10 +125,10 @@ mysql_query($query);
 $query = "INSERT INTO ".$_POST['tableprefix']."messenger VALUES (1,-1,1,'Cool Dude 2k','Test','Hello Welcome to your board.\n\rThis is a Test PM. :P ','Hello Welcome',".$YourDate.",0)";
 mysql_query($query);
 $CHMOD = $_SERVER['PHP_SELF'];
-$pretext = "<?php\n/*\n    This program is free software; you can redistribute it and/or modify\n    it under the terms of the GNU General Public License as published by\n    the Free Software Foundation; either version 2 of the License, or\n    (at your option) any later version.\n\n    This program is distributed in the hope that it will be useful,\n    but WITHOUT ANY WARRANTY; without even the implied warranty of\n    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n    Revised BSD License for more details.\n\n    Copyright 2004-2007 Cool Dude 2k - http://intdb.sourceforge.net/\n    Copyright 2004-2007 Game Maker 2k - http://upload.idb.s1.jcink.com/\n    iDB Installer made by Game Maker 2k - http://idb.berlios.net/\n\n    \$FileInfo: settings.php & settingsbak.php - Last Update: 05/09/2007 SVN 1 - Author: cooldude2k \$\n*/\n";
+$pretext = "<?php\n/*\n    This program is free software; you can redistribute it and/or modify\n    it under the terms of the GNU General Public License as published by\n    the Free Software Foundation; either version 2 of the License, or\n    (at your option) any later version.\n\n    This program is distributed in the hope that it will be useful,\n    but WITHOUT ANY WARRANTY; without even the implied warranty of\n    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n    Revised BSD License for more details.\n\n    Copyright 2004-2007 Cool Dude 2k - http://intdb.sourceforge.net/\n    Copyright 2004-2007 Game Maker 2k - http://upload.idb.s1.jcink.com/\n    iDB Installer made by Game Maker 2k - http://idb.berlios.net/\n\n    \$FileInfo: settings.php & settingsbak.php - Last Update: 05/14/2007 SVN 6 - Author: cooldude2k \$\n*/\n";
 $pretext2 = array("/*   Board Setting Section Begins   */\n\$Settings = array();","/*   Board Setting Section Ends  \n     Board Info Section Begins   */\n\$SettInfo = array();","/*   Board Setting Section Ends   \n     Board Dir Section Begins   */\n\$SettDir = array();","/*   Board Dir Section Ends   */");
 $settcheck = "if (\$File3Name==\"settings.php\"||\$File3Name==\"/settings.php\"||\n    \$File3Name==\"settingsbak.php\"||\$File3Name==\"/settingsbak.php\") {\n    @header('Location: index.php');\n    exit(); }\n";
-$BoardSettings=$pretext2[0]."\n\$Settings['sqlhost'] = '".$_POST['DatabaseHost']."';\n\$Settings['sqldb'] = '".$_POST['DatabaseName']."';\n\$Settings['sqltable'] = '".$_POST['tableprefix']."';\n\$Settings['sqluser'] = '".$_POST['DatabaseUserName']."';\n\$Settings['sqlpass'] = '".$_POST['DatabasePassword']."';\n\$Settings['board_name'] = '".$_POST['NewBoardName']."';\n\$Settings['idbdir'] = '".$idbdir."';\n\$Settings['idburl'] = '".$_POST['BoardURL']."';\n\$Settings['weburl'] = '".$_POST['WebURL']."';\n\$Settings['use_gzip'] = ".$_POST['GZip'].";\n\$Settings['html_type'] = '".$_POST['HTMLType']."';\n\$Settings['html_level'] = '".$_POST['HTMLLevel']."';\n\$Settings['output_type'] = '".$_POST['OutPutType']."';\n\$Settings['GuestGroup'] = 'Guest';\n\$Settings['MemberGroup'] = 'Member';\n\$Settings['ValidateGroup'] = 'Validate';\n\$Settings['AdminValidate'] = false;\n\$Settings['TestReferer'] = ".$_POST['TestReferer'].";\n\$Settings['DefaultTheme'] = 'iDB';\n\$Settings['DefaultTimeZone'] = '".$AdminTime."';\n\$Settings['DefaultDST'] = '".$AdminDST."';\n\$Settings['charset'] = 'iso-8859-15';\n\$Settings['add_power_by'] = false;\n\$Settings['send_pagesize'] = false;\n\$Settings['max_posts'] = '10';\n\$Settings['max_topics'] = '10';\n\$Settings['hot_topic_num'] = '15';\n\$Settings['qstr'] = '&';\n\$Settings['qsep'] = '=';\n\$Settings['file_ext'] = '.php';\n\$Settings['rss_ext'] = '.php';\n\$Settings['js_ext'] = '.js';\n\$Settings['showverinfo'] = true;\n\$Settings['enable_rss'] = true;\n\$Settings['EnableToggle'] = true;\n\$Settings['fixpathinfo'] = false;\n\$Settings['fixbasedir'] = false;\n\$Settings['rssurl'] = false;\n".$pretext2[1]."\n\$SettInfo['board_name'] = '".$_POST['NewBoardName']."';\n\$SettInfo['Author'] = '".$_POST['AdminUser']."';\n\$SettInfo['Keywords'] = '".$_POST['NewBoardName'].",".$_POST['AdminUser']."';\n\$SettInfo['Description'] = '".$_POST['NewBoardName'].",".$_POST['AdminUser']."';\n".$pretext2[2]."\n\$SettDir['maindir'] = '".$idbdir."';\n\$SettDir['inc'] = 'inc/';\n\$SettDir['misc'] = 'inc/misc/';\n\$SettDir['admin'] = 'inc/admin/';\n\$SettDir['mod'] = 'inc/mod/';\n\$SettDir['themes'] = 'themes/';\n".$pretext2[3]."\n?>";
+$BoardSettings=$pretext2[0]."\n\$Settings['sqlhost'] = '".$_POST['DatabaseHost']."';\n\$Settings['sqldb'] = '".$_POST['DatabaseName']."';\n\$Settings['sqltable'] = '".$_POST['tableprefix']."';\n\$Settings['sqluser'] = '".$_POST['DatabaseUserName']."';\n\$Settings['sqlpass'] = '".$_POST['DatabasePassword']."';\n\$Settings['board_name'] = '".$_POST['NewBoardName']."';\n\$Settings['idbdir'] = '".$idbdir."';\n\$Settings['idburl'] = '".$_POST['BoardURL']."';\n\$Settings['weburl'] = '".$_POST['WebURL']."';\n\$Settings['use_gzip'] = '".$_POST['GZip']."';\n\$Settings['html_type'] = '".$_POST['HTMLType']."';\n\$Settings['html_level'] = '".$_POST['HTMLLevel']."';\n\$Settings['output_type'] = '".$_POST['OutPutType']."';\n\$Settings['GuestGroup'] = 'Guest';\n\$Settings['MemberGroup'] = 'Member';\n\$Settings['ValidateGroup'] = 'Validate';\n\$Settings['AdminValidate'] = false;\n\$Settings['TestReferer'] = ".$_POST['TestReferer'].";\n\$Settings['DefaultTheme'] = 'iDB';\n\$Settings['DefaultTimeZone'] = '".$AdminTime."';\n\$Settings['DefaultDST'] = '".$AdminDST."';\n\$Settings['charset'] = 'iso-8859-15';\n\$Settings['add_power_by'] = false;\n\$Settings['send_pagesize'] = false;\n\$Settings['max_posts'] = '10';\n\$Settings['max_topics'] = '10';\n\$Settings['hot_topic_num'] = '15';\n\$Settings['qstr'] = '&';\n\$Settings['qsep'] = '=';\n\$Settings['file_ext'] = '.php';\n\$Settings['rss_ext'] = '.php';\n\$Settings['js_ext'] = '.js';\n\$Settings['showverinfo'] = true;\n\$Settings['enable_rss'] = true;\n\$Settings['EnableToggle'] = true;\n\$Settings['fixpathinfo'] = false;\n\$Settings['fixbasedir'] = false;\n\$Settings['rssurl'] = false;\n".$pretext2[1]."\n\$SettInfo['board_name'] = '".$_POST['NewBoardName']."';\n\$SettInfo['Author'] = '".$_POST['AdminUser']."';\n\$SettInfo['Keywords'] = '".$_POST['NewBoardName'].",".$_POST['AdminUser']."';\n\$SettInfo['Description'] = '".$_POST['NewBoardName'].",".$_POST['AdminUser']."';\n".$pretext2[2]."\n\$SettDir['maindir'] = '".$idbdir."';\n\$SettDir['inc'] = 'inc/';\n\$SettDir['misc'] = 'inc/misc/';\n\$SettDir['admin'] = 'inc/admin/';\n\$SettDir['mod'] = 'inc/mod/';\n\$SettDir['themes'] = 'themes/';\n".$pretext2[3]."\n?>";
 $BoardSettingsBak = $pretext.$settcheck.$BoardSettings;
 $BoardSettings = $pretext.$settcheck.$BoardSettings;
 $fp = fopen("settings.php","w+");
index 6de067f..7fdf651 100644 (file)
@@ -12,7 +12,7 @@
     Copyright 2004-2007 Game Maker 2k - http://upload.idb.s1.jcink.com/
     iDB Installer made by Game Maker 2k - http://idb.berlios.net/
 
-    $FileInfo: setup.php - Last Update: 05/09/2007 SVN 1 - Author: cooldude2k $
+    $FileInfo: setup.php - Last Update: 05/14/2007 SVN 6 - Author: cooldude2k $
 */
 $File1Name = dirname($_SERVER['SCRIPT_NAME'])."/";
 $File2Name = $_SERVER['SCRIPT_NAME'];
@@ -83,10 +83,12 @@ fclose($fp);
        <td style="width: 50%;"><label class="TextBoxLabel" for="WebURL">Insert The WebSite URL:</label></td>
        <td style="width: 50%;"><input type="text" class="TextBox" name="WebURL" size="20" id="WebURL" value="<?php echo $prehost.$_SERVER['HTTP_HOST']."/"; ?>" /></td>
 </tr><tr>
-       <td style="width: 50%;"><label class="TextBoxLabel" for="UseGzip">Do you want to GZip Pages:</label></td>
+       <td style="width: 50%;"><label class="TextBoxLabel" title="Can save some bandwidth." for="UseGzip">Do you want to HTTP Content Compression:</label></td>
        <td style="width: 50%;"><select size="1" class="TextBox" name="GZip" id="UseGzip">
-       <option value="false">No</option>
-       <option value="true">Yes</option>
+       <option value="off">No</option>
+       <option value="on">Yes</option>
+       <option value="gzip">Only GZip</option>
+       <option value="deflate">Only Deflate</option>
        </select></td>
 </tr><tr>
        <td style="width: 50%;"><label class="TextBoxLabel" for="HTMLType">HTML Type to use:</label></td>
index ba7e62a..933768d 100644 (file)
@@ -11,7 +11,7 @@
     Copyright 2004-2006 Cool Dude 2k - http://intdb.sourceforge.net/\r
     Copyright 2004-2006 Game Maker 2k - http://upload.idb.s1.jcink.com/\r
 \r
-    $FileInfo: info.php - Last Update: 05/14/2007 SVN 5 - Author: cooldude2k $\r
+    $FileInfo: info.php - Last Update: 05/14/2007 SVN 6 - Author: cooldude2k $\r
 */\r
 $ThemeInfo = array();\r
 $ThemeInfo['ThemeName'] = "iDB Theme";\r
index 355d33b..d3fe79c 100644 (file)
     Copyright 2004-2006 Cool Dude 2k - http://intdb.sourceforge.net/\r
     Copyright 2004-2006 Game Maker 2k - http://upload.idb.s1.jcink.com/\r
 \r
-    $FileInfo: settings.php - Last Update: 05/14/2007 SVN 5 - Author: cooldude2k $\r
+    $FileInfo: settings.php - Last Update: 05/14/2007 SVN 6 - Author: cooldude2k $\r
 */\r
 $ThemeSet = array();\r
 $ThemeSet['ThemeName'] = "iDB Theme";\r
 $ThemeSet['ThemeMaker'] = "Cool Dude 2k";\r
 $ThemeSet['ThemeVersion'] = "0.1.5";\r
 $ThemeSet['ThemeVersionType'] = "Pre-Alpha";\r
-$ThemeSet['ThemeSubVersion'] = "SVN 5";\r
+$ThemeSet['ThemeSubVersion'] = "SVN 6";\r
 $ThemeSet['MakerURL'] = "http://upload.idb.s1.jcink.com/";\r
 $ThemeSet['CopyRight'] = $ThemeSet['ThemeName']." was made by <a href=\"".$ThemeSet['MakerURL']."\" title=\"".$ThemeSet['ThemeMaker']."\">".$ThemeSet['ThemeMaker']."</a>";\r
 $ThemeSet['CSS'] = "themes/iDB/css.css";\r