currently I have a strange problem.
I am using the following lines:
$path = "/path/to/test.pdf"
$response = new \Phalcon\Http\Response();
$response->setHeader("Cache-Control", 'must-revalidate, post-check=0, pre-check=0');
$response->setHeader('Content-Disposition', 'inline; filename=' . urlencode($filename));
$response->setFileToSend($path, null, false);
In Firefox it works fine and the PDF is shown properly.
But when I call the URL with this method in Chrome, Chrome says "Error while loading file".
I don't really know what the problem is. Do I have any mistake in my code?
Thanks a lot!