[eluser]sl3dg3hamm3r[/eluser]
okay, after playing around I figured out that it was a classical output before header, because I was simply echoing the pdf-stream in my library. d'oh!
That's how it should be used correctly:
Code:
$this->CI->output->set_header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // some day in the past to avoid cached files
$this->CI->output->set_header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
$this->CI->output->set_header("Content-type: application/pdf"); // It is a pdf...
$date = gmdate("d.m.Y") . "_" . date("H_i");
$this->CI->output->set_header("Content-Disposition: attachment; filename=".$fileName."_".$date.".pdf");
$this->CI->output->set_header("Content-Transfer-Encoding: binary");
$pdfStream = $this->CI->cezpdf->ezOutput();
$this->CI->output->set_output($pdfStream);
It is then in the hands of CI to set the headers and send the content after!
By the way: If you don't want to set your headers yourself, you can use
Code:
$this->CI->cezpdf->ezStream();
The pdf-library will set some standard-headers itself. But note, they can't be overwritten anymore since the output will be also echoed straight away by the library.