Using Expires directive for frill images directory.

ISAPI_Rewrite is Apache mod_rewrite compatible URL rewriter for Microsoft IIS
User avatar
Posts: 33
Joined: 18 Jul 2012, 07:50

Using Expires directive for frill images directory.

18 Apr 2013, 08:36

I am trying to apply the Expires Header on all images that exists und /stylesheet folder. But unfortunately can't find an help.

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: Using Expires directive for frill images directory.

18 Apr 2013, 14:18

Hello,

The RewriteHeader directive is described here - http://www.helicontech.com/isapi_rewrite/doc/RewriteHeader.htm

Regards
Andrew

User avatar
Posts: 33
Joined: 18 Jul 2012, 07:50

Re: Using Expires directive for frill images directory.

19 Apr 2013, 07:09

Thank you for your response.

If i try to cache the images saved un stylesheets folder for one month, will it be OK if I write my rules like

Code: Select all
RewriteCond %{REQUEST_URI} stylesheets/.*\.(gif|jpg|png) [NC]
RewriteHeader Expires :  A2592000

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: Using Expires directive for frill images directory.

19 Apr 2013, 09:39

It seems like you night a slightly different one.
You need to set up response header Cache-Control: max-age=2592000,public, but ISAPI_Rewrite can't do it.
You can d it using either HeliconApe, or in IIS for the stylesheets folder by creating a custom response header.

Regards
Andrew

Return to ISAPI_Rewrite 3.0

Who is online

Users browsing this forum: No registered users and 18 guests