Corrected the check for magic_quotes_gpc which is important to know when configuration values are saved into the DB

This commit is contained in:
Andre Lorbach 2008-10-22 16:13:16 +02:00
parent 0256ace844
commit c9e066f486

View File

@ -246,7 +246,7 @@ function DB_RemoveBadChars($myString, $dbEngine = DB_MYSQL)
else else
{ {
// Replace with internal PHP Functions! // Replace with internal PHP Functions!
if ( !get_magic_quotes_runtime() ) if ( !get_magic_quotes_gpc() )
return addslashes($myString); return addslashes($myString);
// return addcslashes($myString, "'"); // return addcslashes($myString, "'");
else else
@ -263,7 +263,7 @@ function DB_RemoveBadChars($myString, $dbEngine = DB_MYSQL)
function DB_StripSlahes($myString) function DB_StripSlahes($myString)
{ {
// Replace with internal PHP Functions! // Replace with internal PHP Functions!
if ( !get_magic_quotes_runtime() ) if ( !get_magic_quotes_gpc() )
return stripslashes($myString); return stripslashes($myString);
else else
return $myString; return $myString;