Wusage 8.0 Manual
rewrite Option
To reach this option in the configuration file editor,
follow these steps:
1. Edit Configuration
2. Configure Filters...
3. Rewrite Rules...
If you prefer to manually edit your configuration files,
use the following syntax for this option:
Example
#Rewrite URLs beginning with an old pathname. The new version
#begins with a different pathname and ends with the remainder
#of the original path. This allows many different document URLs
#to be rewritten using a single rule.
url /oldpath* /newpath\1
Description
Frequently documents will move from one directory to another,
or from one server to another, resulting in two copies of the
same document which would ideally be counted as the same
document. The Rewrite Rules (rewrite) option makes it possible to
handle this situation and many similar situations affecting
document names as well as other log entry fields.
The Rewrite Rules (rewrite) option uses the same set of pattern
and regular expression matching features used by many other
options, with the addition of "rewrite rules" that allow items
matched by * in patterns (or by ( and
) in regular expressions) to be inserted as part
of the rewritten document name or other log entry field.
See the Patterns and Regular Expressions
section for more information.
To insert the first such item in the rewrite rule, use the
syntax \1 . To insert the second such item,
use the syntax \2 , and so on.
The following fields can be rewritten using the Rewrite Rules (rewrite) option:
site (see Chart Top Sites (sites))
authname (see Chart Top Authorized Users (authusers))
url (see Chart Top Documents (documents))
referrer (see Chart Top Referring URLs (referrers))
useragent (see Chart Top Web Browsers (useragents))
os (see Chart Top Operating Systems (os))
servername (see (servername))
cookie (see Chart Top Users (Determined By Cookies) (users))
Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, Boutell.Com, Inc.
wusage@boutell.com
Boutell.Com, Inc - PO Box 16716, Seattle WA, 98116, USA
Phone/Fax +1 206 658-8176
|