diff --git a/include/class.file.php b/include/class.file.php index c27c9fdd07b5aa7477336c009af2fdb75605233c..e4012bb4b9f7665438cc28fbc3818162f48579a7 100644 --- a/include/class.file.php +++ b/include/class.file.php @@ -108,7 +108,7 @@ class AttachmentFile { function display() { - header('Content-type: '.$this->getType()?$this->getType():'application/octet-stream'); + header('Content-Type: '.($this->getType()?$this->getType():'application/octet-stream')); header('Content-Length: '.$this->getSize()); echo $this->getData(); exit(); @@ -120,9 +120,7 @@ class AttachmentFile { header('Expires: 0'); header('Cache-Control: must-revalidate, post-check=0, pre-check=0'); header('Cache-Control: public'); - header('Content-Type: application/octet-stream'); - - //header('Content-Type: '.$this->getType()?$this->getType():'application/octet-stream'); + header('Content-Type: '.($this->getType()?$this->getType():'application/octet-stream')); $filename=basename($this->getName()); $user_agent = strtolower ($_SERVER['HTTP_USER_AGENT']);