Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Great Tutorial on .htaccess
This works very well for us.. so I thought I would share it..It's easy and effective.

<Files ~ "^\.ht">
Order allow,deny
Deny from all
Satisfy All

RewriteEngine On
RewriteRule .* - [F]
ServerSignature Off
ExpiresActive On
ExpiresDefault "access plus 1 seconds"
ExpiresByType text/html "access plus 1 seconds"
ExpiresByType image/gif "access plus 120 minutes"
ExpiresByType image/jpeg "access plus 120 minutes"
ExpiresByType image/png "access plus 120 minutes"
ExpiresByType text/css "access plus 60 minutes"
ExpiresByType text/javascript "access plus 60 minutes"
ExpiresByType application/x-javascript "access plus 60 minutes"
ExpiresByType text/xml "access plus 1 seconds"

What this does...
It does a few things:

1. the beginning denies all malicious access to .htaccess and htpasswd files
2. the second part denies all HEAD requests to domain ( lame kind of DDOS)
3. the 3d part doesn't allow pinging of your domain for server info, what type, cpu, mods installed etc.
4. the last part is about caching your forum. And it will become faster, especially if you use a lot of images etc.
All html is on 1 second and thus new topics you will see instant, the CSS file is cached for 60 minutes as well as javascripts of mods and mybb board.
All images are cached for 120 minutes.
This reduces the reload of images css etc etc by members browsers which results in lesser bandwidth and faster loading.

I have tested this on my forum with success hope you enjoy friends.
wow great ^^ in sure omni would like to consider this...
Testing it.


Looks good Smile
vBulletin Developer
My Forum
My Blog
thank you Smile
cool, done! Smile

Forum Jump:

Users browsing this thread: 1 Guest(s)