<?
class c_services_get_log
{
 function show()
 {  if ($_GET['fname']) $cont=file_get_contents($_SERVER['DOCUMENT_ROOT'].'/logs/'.$_GET['fname']) ;
    if ($cont)
    { header('Content-Description: File Transfer');
      header('Content-Transfer-Encoding: binary');
      header('Cache-Control: public, must-revalidate, max-age=0');
      header('Pragma: public');
      header('Expires: Sat, 26 Jul 1997 05:00:00 GMT');
      header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
      header('Content-Length: '.strlen($cont));
      header('Content-Type: application/force-download');
      header('Content-Type: application/octet-stream', false);
      header('Content-Type: application/download', false);
      header('Content-disposition: attachment; filename="'.basename($_GET['fname']).'"');
      echo $cont ;
    } else echo 'Файл не найден' ;
 }
}

?>