2 require_once(
"$admLibrary/ck_aticket.i");
3 $protectdir = $home_path;
5 $filename = $protectdir . $_SERVER[
'PATH_INFO'];
6 if (is_readable($filename)) {
7 $fileonly = basename($filename);
8 $filetype = substr($fileonly,-4);
9 if ($filetype ==
".tab" || $filetype ==
".zip") {
10 $s_array=stat($filename);
11 $size=$s_array[
"size"];
12 if (strstr($_SERVER[
"HTTP_USER_AGENT"],
"MSIE")) {
13 header(
"Content-Disposition: filename=$fileonly");
15 header(
"Content-Disposition: attachment; filename=$fileonly");
17 if ($filetype ==
".zip") {
18 header(
"Content-Type: application/zip");
20 header(
"Content-type: application/octet-stream");
22 header(
"Content-Length: $size");
23 header(
"Accept-Ranges: bytes");
28 header(
"Status: 404 Not Found");
31 The requested URL ${_SERVER[
'PHP_SELF']} was not found on
this server.<P>
33 <ADDRESS>${_SERVER[
'SERVER_SIGNATURE']}</ADDRESS>