$v) { $b[$k] = addslashes_array($v); } return $b; } else { return my_addslashes($a); } } // Seit Firefox 48.0 wird offensichtlich in jedem Fall Unicode in den Get-Vars �bertragen, auch wenn die Website selbst nicht Unicode ist. // Daher m�ssen die Parameter mit potentiellen Umlauten erst decoded werden (siehe auch job_options.php). foreach ($_GET as $k => $v) { // $_GET[$k] = preg_replace("/([\xC2\xC3])([\x80-\xBF])/e", "chr(ord('\\1')<<6&0xC0|ord('\\2')&0x3F)", $v); $_GET[$k] = preg_replace_callback("/([\xC2\xC3])([\x80-\xBF])/", function ($matches) { foreach ($matches as $match) { return chr(ord($match) . "<<6&0xC0|" . ord($match) . "&0x3F"); }; }, $v ); } //print_r($_POST); # https://www.php.net/manual/en/function.get-magic-quotes-gpc.php # => get_magic_quotes_gpc() DEPRECATED as of PHP 7.4.0, and REMOVED as of PHP 8.0.0. # # also see https://stackoverflow.com/questions/61054418/php-7-4-deprecated-get-magic-quotes-gpc-function-alternative # => Since PHP no longer adds slashes to request parameters (removed in PHP 5.4), get_magic_quotes_gpc() always returns false. # With that in mind, you don't have to do anything to your strings, they should always be clean. //if (!get_magic_quotes_gpc()) { if (!false) { if (!empty($HTTP_POST_VARS)) { foreach ($HTTP_POST_VARS as $k => $v) { $HTTP_POST_VARS[$k] = addslashes_array($v); } } else { foreach ($_POST as $k => $v) { $_POST[$k] = addslashes_array($v); } } if (!empty($HTTP_GET_VARS)) { foreach ($HTTP_GET_VARS as $k => $v) { $HTTP_GET_VARS[$k] = addslashes_array($v); } } else { foreach ($_GET as $k => $v) { $_GET[$k] = addslashes_array($v); } } } //print_r($_POST); $HTTP_POST_VARS = !empty($HTTP_POST_VARS) ? $HTTP_POST_VARS : $_POST; $HTTP_GET_VARS = !empty($HTTP_GET_VARS) ? $HTTP_GET_VARS : $_GET; $HTTP_COOKIE_VARS = !empty($HTTP_COOKIE_VARS) ? $HTTP_COOKIE_VARS : $_COOKIE; $HTTP_SERVER_VARS = !empty($HTTP_SERVER_VARS) ? $HTTP_SERVER_VARS : $_SERVER; $HTTP_ENV_VARS = !empty($HTTP_ENV_VARS) ? $HTTP_ENV_VARS : $_ENV; $HTTP_POST_FILES = !empty($HTTP_POST_FILES) ? $HTTP_POST_FILES : $_FILES; // Array for 2-way-encryption containing primes $eca[0] = "441523"; $eca[1] = "333433"; $eca[2] = "489733"; $eca[3] = "515993"; $eca[4] = "173099"; $priceFormular = "SUM(trs.trs_price * ((100 - trs.trs_discount) / 100))"; if (!isset($PHP_SELF)) $PHP_SELF = $_SERVER["PHP_SELF"]; $languageText = array(); // Global associative array for language texts to be diplayed $languageSelected = "0"; // Language selected ["0" = German, "1" = English, ...] $languageDBUpdateMode = "1"; // If activated (= "1") then check existence of language text in the database $currentScript = ""; // Current name of the script $GLOBAL_USAGE_HASH = true; // Global regulation for usage of the external HASH structure $GLOBAL_DB_IS_LIVE = false; // THIS DB instance is LIVE (!!!!) // Wrapper for deprecated functions $phpVersion = substr(phpversion(), 0, 3); if ($phpVersion >= "7.0") : function spliti ($delimiter, $string) { return explode($delimiter, $string); }; function split ($delimiter, $string) { return explode($delimiter, $string); }; function ereg_replace ($pattern, $replacement, $string) { return preg_replace("/" . $pattern . "/", $replacement, $string); }; function ereg ($pattern, $subject) { return preg_match("/" . $pattern . "/", $subject); }; endif; function mcIsSet (&$var, $initVal = "") { if (!isset($var)) { $var = $initVal; }; return $var; }; function mcTrim (&$str, $initVal = "") { $str = trim(mcIsSet($str, $initVal)); return $str;}; function mcArrIsSet (&$arr, $key, $initVal = "") { $arr[$key] = (array_key_exists($key, $arr) ? $arr[$key] : $initVal); return $arr[$key]; }; function mcArrMultiDimIsSet (&$arr, $key, $initVal = "") { return (array_key_exists($key, $arr??[]) ? $arr[$key] : $initVal); }; function mcArrTrim (&$arr, $key) { return trim(mcArrIsSet($arr, $key)); }; function mcChkValOrArrCountIsEmpty (&$var) { return ( mcIsSet($var) == "" || (is_array($var) && count($var) == 0) ? true : false); }; function mcArrCount ($arr, $retVal = 1) { return (is_array($arr) ? count($arr) : $retVal); }; // Global variables mcIsSet($usedFramework); mcIsSet($deactivateMenuStatic); mcIsSet($customerId); mcIsSet($cscIdRoot); mcIsSet($cscIdActual); mcIsSet($cscNameCurrent); mcIsSet($htmlDefaultCharset); mcIsSet($hqId); mcIsSet($emp_id); mcIsSet($usr_id); mcIsSet($automailer); mcIsSet($dbhistory); mcIsSet($statusMessage); $f_secretFileName = ""; $summationField = ""; $summationField2 = ""; $summationField3 = ""; $summationField4= ""; $summationField5 = ""; $summationField6 = ""; $summationField7= ""; $summationField8 = ""; $summationField9 = ""; $sumOfSummationField = ""; $sumOfSummationField2 = ""; $sumOfSummationField3 = ""; $sumOfSummationField4 = ""; $sumOfSummationField5 = ""; $sumOfSummationField6 = ""; $sumOfSummationField7 = ""; $sumOfSummationField8 = ""; $sumOfSummationField9 = ""; $summationFieldArrayLen = 0; ?>