Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: [TIP] Save Bandwith w/ a .htaccess file  (Read 2795 times)

0 Members and 1 Guest are viewing this topic.

cordis

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
[TIP] Save Bandwith w/ a .htaccess file
« on: November 15, 2004, 08:22:15 pm »

.htaccess file

Code: [Select]
SetEnvIfNoCase Referer "^http://www.mydomain.com/" locally_linked=1
SetEnvIfNoCase Referer "^http://www.mydomain.com$" locally_linked=1
SetEnvIf Referer "^$" locally_linked=1
<FilesMatch "\.([gG][iI][fF]|[pP][nN][gG]|[jJ][pP][gG]|[sS][wW][fF]|[aA][vV][iI]|[mM][pP]3|[wW][mM][fF]|[wW][aA][vV])$">
  Order Allow,Deny
  Allow from env=locally_linked
</FilesMatch>

case insensitive FilesMatch.
Logged

SaigonK

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Gender: Male
  • Posts: 59
Re: [TIP] Save Bandwith w/ a .htaccess file
« Reply #1 on: November 16, 2004, 01:42:08 am »

How would this work, what savings does it create?
My gallery seems awful slow as of late, not sure if the database is just big or what, it is only 1.7MB, so that cant be it...

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: [TIP] Save Bandwith w/ a .htaccess file
« Reply #2 on: November 16, 2004, 05:41:31 am »

the code posted is meant as hotlink protection, there are already some postings in the mods section that discuss this in more detail - it won't speed up your site though. If you have troubles with speed/performance, you should post a link to your site, so we can take a look and tell you what is probably consuming most resources on load.

Joachim
Logged
Pages: [1]   Go Up
 

Page created in 0.016 seconds with 15 queries.