| Server IP : 172.67.178.83 / Your IP : 216.73.217.141 Web Server : Apache System : Linux hosting01.arsenalhost.com 4.18.0-425.13.1.lve.el8.x86_64 #1 SMP Mon Feb 27 15:23:24 EST 2023 x86_64 User : corbizre ( 1013) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/corbizre/rentalssearch.com/lib/ |
Upload File : |
<?php
function getvar($tKey, $tSrcArr, $tDefValue=false)
{
$res = $tDefValue;
if (isset($tSrcArr[$tKey])){
$res = $tSrcArr[$tKey];
}
return $res;
}
function replace_images($template_content)
{
$allchars = '-:=%;a-zA-Z\\/0-9_\. ';
$eregReplacePattern = "(<img[$allchars\'\"]*src=)([\"'])([$allchars]*)([\"'])";
return preg_replace('/' . addcslashes($eregReplacePattern, '/') . '/', "\\1\\2". HTTP_PATH ."\\3\\4", $template_content);
}
function getstr($key, $arr, $defval = '')
{
return trim(stripslashes(getvar($key, $arr, $defval)));
}
function getint($key, $arr, $defval = 0)
{
$str = getstr($key, $arr, $defval);
if (preg_match('/^\-{0,1}[0-9]+$/', $str)){
return $str;
}
return $defval;
}
function isArray($arr)
{
return is_array($arr) && count($arr) > 0;
}
function is_ie()
{
return substr_count($_SERVER['HTTP_USER_AGENT'], 'MSIE 6.0') > 0;
}
function is_validator()
{
return substr_count($_SERVER['HTTP_USER_AGENT'], 'W3C_Validator') > 0;
}
function is_gecko()
{
return substr_count($_SERVER['HTTP_USER_AGENT'], 'Gecko') > 0;
}
function gebug($debug,$message){
if($debug){ echo $message;}
}
function print_gzipped_page() {
global $HTTP_ACCEPT_ENCODING;
if( headers_sent() ){
$encoding = false;
}elseif( strpos($HTTP_ACCEPT_ENCODING, 'x-gzip') !== false ){
$encoding = 'x-gzip';
}elseif( strpos($HTTP_ACCEPT_ENCODING,'gzip') !== false ){
$encoding = 'gzip';
}else{
$encoding = false;
}
if( $encoding ){
$contents = ob_get_contents();
ob_end_clean();
header('Content-Encoding: '.$encoding);
print("\x1f\x8b\x08\x00\x00\x00\x00\x00");
$size = strlen($contents);
$contents = gzcompress($contents, 9);
$contents = substr($contents, 0, $size);
print($contents);
exit();
}else{
ob_end_flush();
exit();
}
}
?>