Your Ad Here

Friday, February 6, 2009

force pdf to download?

Hi
need to force pdf to download instead of opening in browser window.

Have tried both of the following in a htaccess file in the pdf dir:

Code:
---------
Header add Content-Disposition "Attachment"
---------

Code:
---------
SetEnvIf Request_URI "\.pdf$" requested_pdf=pdf Header add Content-Disposition "Attachment" env=requested_pdf
---------
but neither seem to make an ounce of difference. (although when I first tried them I got a 500 error for both that seems to have disappeared since.)

I have the code as is with nothing else in the htaccess file as the site I got it from was kinda sparse on info on using the code.

anyone know any different??

ta

Read More...

[Source: Code Forums - Posted by Kishore Vengala]
Your Ad Here

No comments: