Jump to content

Problems with cache settings in .htaccess


Moldarin

Recommended Posts

Hi,

What is wrong with these cache settings in my .htaccess configuration file? I get a 500 error on my site when trying to implement them.

[code]ExpiresActive On
<Directory "/home/content/html/lib/images/">
AllowOverride Indexes
ExpiresDefault "access 3 months"
</Directory>
<Directory "/home/content/html/lib/script/">
AllowOverride Indexes
ExpiresDefault "access 3 months"
</Directory>
<Directory "/home/content/html/lib/style/">
AllowOverride Indexes
ExpiresDefault "access 5 weeks"
</Directory>[/code][i]Code from /home/content/html/.htaccess[/i]
Link to comment
https://forums.phpfreaks.com/topic/31254-problems-with-cache-settings-in-htaccess/
Share on other sites

As far as i know they <Directory> can't be used in .HTACCESS and should be in the HTTPD.conf file.

Try this, and put the seperate .HTACCESS files in theire appropriate directories

[code]
ExpiresActive On
AllowOverride Indexes
ExpiresDefault "access 3 months"
...
[/code]

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.