Server IP : 80.87.202.40 / Your IP : 216.73.216.169 Web Server : Apache System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64 User : bitrix ( 600) PHP Version : 8.2.27 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/support/classes/general/ |
Upload File : |
<?php class CSupportTools { static $speedArray = array(); static function PrepareParamArray($param, $res = array()) { if(is_string($param) && $param <> '') { $res = explode(",", $param); foreach( $res as $k => $v ) $res[$k] = trim($v); } elseif(is_array($param) && count($param) > 0) $res = $param; elseif(is_int($param)) $res = array($param); return $res; } // $more0 = "strlen || count || intval" static function array_keys_exists($key, $arr, $more0 = "", $andOr = "&&") { $arrKeys = self::prepareParamArray($key); $arrMore0 = self::prepareParamArray($more0); $res = true; foreach($arrKeys as $k => $v) { $resC = (is_array($arr) && array_key_exists($v, $arr) && (!in_array("strlen", $arrMore0) || (string) $arr[$v] <> '') && (!in_array("count", $arrMore0) || ( is_array($arr[$v]) && count($arr[$v] ) > 0)) && (!in_array("intval", $arrMore0) || intval($arr[$v]) > 0) ); if($andOr == "||") $res = ($res || $resC); elseif(!$resC) return false; } return $res; } } ?>