• Welcome to the Chevereto User Community!

    Here, users from all over the world come together to learn, share, and collaborate on everything related to Chevereto. It's a place to exchange ideas, ask questions, and help improve the software.

    Please keep in mind:

    • This community is user-driven. Always be polite and respectful to others.
    • Support development by purchasing a Chevereto license, which also gives you priority support.
    • Go further by joining the Community Subscription for even faster response times and to help sustain this space

[GUIDE] Force Direct Link Image Download

stuart

Chevereto Member
Hi Guys,

I did a bit of research into direct image downloading and while I don't mind people downloading the images I don't want people sending traffic directly to my images as this wastes my bandwidth and I get no advertising revenue!

The solution was to add the following to my .htaccess file within my root directory:

<FilesMatch "\.(jpg|jpeg|png|gif)$" >
ForceType application/octet-stream
Header add Content-Disposition "attachment"
</FilesMatch>

What this does is still allows your local site to embed images but if anyone trys to visit the image directly in /images/imagename.jpg it forces them to download it with a standard download box 🙂

Problem solved and no script editing required!
 
Back
Top