You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 10, 2025. It is now read-only.
Consider a site that is static html with a dynamic directory:
/index.html
/about.html
/images/
/cgi-bin/
/stylesheets/
/scripts/
/subdirA/
/subdirB/
/subdirC/
...
They would like to set:
ModPagespeedLoadFromFile "http://www.example.com/" "/var/www/"
But this would break their cgi-bin directory. While they could add separate
"ModPagespeedLoadFromFile" directives for every top-level directory except
cgi-bin, that is awkward, needs to be maintained, doesn't apply to index.html
or other top-level pages, and may slow mod_pagespeed down. Finer-grained
control over LoadFromFile is needed here.
I see two potential solutions, of which I prefer (1):
1) Add a "ModPagespeedDisableLoadFromFile"
configuration directive that takes
priority over ModPagespeedLoadFromFile:
ModPagespeedLoadFromFile "http://www.example.com/" "/var/www/"
ModPagespeedDisableLoadFromFile "http://www.example.com/cgi-bin/"
2) Support directory-level configuration,
with both a ModPagespeedLoadFromFile and
a ModPagespeedDisableLoadFromFile.
<Directory /var/www>
ModPagespeedLoadFromFile
</Directory>
<Directory /var/www/cgi-bin>
ModPagespeedDisableLoadFromFile
</Directory>
In the example of someone with a mostly
dynamic website that has a /static
directory you would have:
<Directory /var/www/static>
ModPagespeedLoadFromFile
</Directory>
(Not loading from file is the default.)
One question is how useful this is: how many sites does it ally to? While
traditionally websites were set up this way, dynamic sites may be the default
now. Many dynamic sites, however, are actually serving static content that has
been "baked" in advance. For example, Movable Type does this by default.
Original issue reported on code.google.com by jefftk@google.com on 11 Jul 2012 at 6:37
Original issue reported on code.google.com by
jefftk@google.comon 11 Jul 2012 at 6:37