Re: Safari and PDF
| From: | Ashley Sheridan | Date: | Tue, 15 Nov 2011 22:36:58 +0000 |
| Subject: | Re: Safari and PDF | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-315698@lists.php.net to get a copy of this message | ||
On Tue, 2011-11-15 at 23:15 +0100, Matijn Woudt wrote:
> On Tue, Nov 15, 2011 at 11:08 PM, HallMarc Websites
> <marc@hallmarcwebsites.com> wrote:
> > I'm sure everyone here is aware that the latest Mac OS and Safari 5.1.x do not
> > support opening PDFs in the browser window with Acrobat Reader plugin anymore. It is now necessary
> > to open them with Preview instead. My question is this, does anyone know if it is possible to force
> > Safari to use Preview with PHP?
> >
>
> Hi,
>
> I don't have a Mac to test, but you can force PDF download with
> Content-Disposition header in php. Look at Example 1 of the manual
> page for the header function:
> http://php.net/manual/en/function.header.php#example-3913
> You might need some check if browser is Safari first..
>
> Cheers,
>
> Matijn
>
I always thought that opening a PDF inside the browser was a rubbish
idea anyway. I've uninstalled Adobe Reader from my work machine now and
the world is a happier place!
--
Thanks,
Ash
http://www.ashleysheridan.co.uk