OSDN Git Service

Small bug fix.
authorKazuki Przyborowski <kazuki.przyborowski@gmail.com>
Sun, 7 Aug 2011 00:06:09 +0000 (00:06 +0000)
committerKazuki Przyborowski <kazuki.przyborowski@gmail.com>
Sun, 7 Aug 2011 00:06:09 +0000 (00:06 +0000)
git-svn-id: svn://svn.code.sf.net/p/intdb/svn/trunk@741 2b68903e-0b30-0410-9a39-a2e4f3c5be39

inc/filename.php
inc/function.php
inc/versioninfo.php

index db8a954..61173ab 100644 (file)
@@ -11,7 +11,7 @@
     Copyright 2004-2011 iDB Support - http://idb.berlios.de/
     Copyright 2004-2011 Game Maker 2k - http://gamemaker2k.org/
 
-    $FileInfo: filename.php - Last Update: 12/07/2010 SVN 600 - Author: cooldude2k $
+    $FileInfo: filename.php - Last Update: 08/06/2011 SVN 741 - Author: cooldude2k $
 */
 $File3Name = basename($_SERVER['SCRIPT_NAME']);
 if ($File3Name=="filename.php"||$File3Name=="/filename.php") {
@@ -39,10 +39,6 @@ if($Settings['idburl']!="localhost"&&$Settings['idburl']!=null) {
        $rssurlon = "on"; $rssurl = $Settings['idburl']; }
 if($Settings['rssurl']!=null&&$Settings['rssurl']!="") {
        $rssurlon = "on"; $rssurl = $Settings['rssurl']; }
-/* In php 6 and up the function get_magic_quotes_gpc dose not exist. 
-   here we make a fake version that always sends false out. :P */
-if(!function_exists('get_magic_quotes_gpc')) {
-function get_magic_quotes_gpc() { return false; } }
 require_once($SettDir['inc'].'versioninfo.php');
 //File naming stuff. <_< 
 $exfile = array(); $exfilerss = array();
index 8338cb0..a40da47 100644 (file)
@@ -11,7 +11,7 @@
     Copyright 2004-2011 iDB Support - http://idb.berlios.de/
     Copyright 2004-2011 Game Maker 2k - http://gamemaker2k.org/
 
-    $FileInfo: function.php - Last Update: 07/31/2011 SVN 733 - Author: cooldude2k $
+    $FileInfo: function.php - Last Update: 08/06/2011 SVN 741 - Author: cooldude2k $
 */
 $File3Name = basename($_SERVER['SCRIPT_NAME']);
 if ($File3Name=="function.php"||$File3Name=="/function.php") {
@@ -20,6 +20,29 @@ if ($File3Name=="function.php"||$File3Name=="/function.php") {
 require_once($SettDir['misc'].'functions.php');
 require_once($SettDir['misc'].'ibbcode.php');
 require_once($SettDir['misc'].'iuntar.php');
+/* In php 6 and up the function get_magic_quotes_gpc dose not exist. 
+   here we make a fake version that always sends false out. :P */
+if(!function_exists('get_magic_quotes_gpc')) {
+function get_magic_quotes_gpc() { return false; } }
+/**
+ * Undo the damage of magic_quotes_gpc if in effect
+ * @return bool
+ * @link http://www.charles-reace.com/blog/2010/07/13/undoing-magic-quotes/
+ */
+function fix_magic_quotes()
+{
+   if (get_magic_quotes_gpc()) {
+      $func = create_function(
+         '&$val, $key',
+         'if(!is_numeric($val)) {$val = stripslashes($val);}'
+      );
+      array_walk_recursive($_GET, $func);
+      array_walk_recursive($_POST, $func);
+      array_walk_recursive($_COOKIE, $func);
+   }
+   return true;
+}
+fix_magic_quotes();
 /* Change Some PHP Settings Fix the & to &amp;
 if($Settings['use_iniset']==true&&$Settings['qstr']!="/") {
 ini_set("arg_separator.output",htmlentities($Settings['qstr'], ENT_QUOTES, $Settings['charset']));
index 717142c..ef14250 100644 (file)
@@ -11,7 +11,7 @@
     Copyright 2008-2011 iDB Support - http://idb.berlios.de/
     Copyright 2008-2011 Game Maker 2k - http://gamemaker2k.org/
 
-    $FileInfo: versioninfo.php - Last Update: 08/04/2011 SVN 740 - Author: cooldude2k $
+    $FileInfo: versioninfo.php - Last Update: 08/06/2011 SVN 741 - Author: cooldude2k $
 */
 $File3Name = basename($_SERVER['SCRIPT_NAME']);
 if ($File3Name=="versioninfo.php"||$File3Name=="/versioninfo.php") {
@@ -27,8 +27,8 @@ function version_info($proname,$subver,$ver,$supver,$reltype,$svnver,$showsvn) {
        return $return_var; }
 // Version number and date stuff. :P
 $VER1[0] = 0; $VER1[1] = 4; $VER1[2] = 7; $VERFull[1] = $VER1[0].".".$VER1[1].".".$VER1[2];
-$VER2[0] = "Alpha"; $VER2[1] = "Al"; $VER2[2] = "SVN"; $SubVerN = 740;
-$SVNDay[0] = 08; $SVNDay[1] = 04; $SVNDay[2] = 2011; $SVNDay[3] = $SVNDay[0]."/".$SVNDay[1]."/".$SVNDay[2];
+$VER2[0] = "Alpha"; $VER2[1] = "Al"; $VER2[2] = "SVN"; $SubVerN = 741;
+$SVNDay[0] = 08; $SVNDay[1] = 06; $SVNDay[2] = 2011; $SVNDay[3] = $SVNDay[0]."/".$SVNDay[1]."/".$SVNDay[2];
 $AltName = "RDB"; $AltName2 = "ReneeDB"; $RName = "iDB"; $SFName = "IntDB";
 $RFullName = "Internet Discussion Boards"; $AltFullName = "Renee Discussion Boards"; $AltGM2k = "ReneeDB Team";
 $VerCheckName = "iDB"; $AltVerCheckName = "RDB"; $AltiDBHome = "http://duckduckgo.com/?q=ReneeDB";