Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
Thread: How can i work around this?
06-23-2010, 12:37 AM #1
- Join Date
- Jun 2010
- Thanked 0 Times in 0 Posts
How can i work around this?
I'm using a component in Joomla and at the moment when you try to download a file you are given this in the url bar
They are able to save the document to there computer and open it that way but i've had comments on how much of a pain that is, Would a .htaccess modification of any kind help?
07-07-2010, 10:54 AM #2
- Join Date
- Mar 2010
- Virginia, USA
- Thanked 5 Times in 5 Posts
Depending on your server's allowed htaccess directives, you can indeed modify this behavior.
You need access to Apache's mod_headers module. Essentially your are doing the opposite of this tutorial.
Where they are setting Content-Disposition to force the immediate download, you need to unset this header.
If that doesn't fix it for you, provide a sample PDF link and I'll take a closer look at the headers and Joomla source.Code:<FilesMatch "\.(?i:pdf)$"> ForceType application/pdf Header unset Content-Disposition </FilesMatch>