This is an old revision of the document!


LSCWP Configuration Settings: Excludes

empty string

Paths containing the listed strings will not be cached. One per line. Each string will be compared to the REQUEST_URI server variable. If there is a match, the URI will not be cached. To indicate the beginning of a string, add ^ to the beginning of the string. To do an exact match, add $ to the end of the string.

Examples

Assume you have the following URIs:

  1. /recipes/baking/
  2. /recipes/baking/cakes
  3. /recipes/baking/brownies
  4. /popular/recipes/baking/

The string /recipes/baking/ will match all four URIs.

The string /recipes/baking/$ will match #1 (because $ indicates exact match).

The string ^/recipes/baking will match #1, #2, and #3 (because ^ indicates the beginning of the URI).

empty string

You can eliminate URLs with certain query strings from being cached. For example, if you don't want to cache any page that is rendered in a purple color scheme, you could enter color=purple in that list (assuming the URL you use to indicate that a page should be purple looks like http://example.com/page?color=purple). You could also enter color to indicate that you don't want to cache any URL where color is specified, regardless of which color it is.

empty string

This is a list of category pages that should not be cached.

empty string

This is a list of tag pages that should not be cached.

empty string

This is a list of cookies that should not be cached. Specifically, do not cache any page where a cookie in this list appears in the request headers.

This option can be more far-reaching than you may realize. If you exclude a cookie that exists on every page of your site, then you are essentially excluding your entire site from being cached.

empty string

This is a list of user agents that should not be cached. Note that this means on a partial match of the user agent.

unchecked

There may be user roles that you wish to exclude from caching. For example, if you are an admin, testing new functionality, you may want to exclude your administrator role from being served from cache until your testing is through.

  • Admin
  • Last modified: 2017/12/20 16:31
  • by Lisa Clarke