The AWStats Extra Sections features are powerfull setup options to allow you to add your own
report not provided by default with AWStats. You can use it to build special reports, like
number of sales for a particular product, marketing reports, counting for a particular
user or agent, etc...
You can define your own charts, you choose here what are rows and columns
keys. This feature is particularly usefull for marketing purpose, tracking
products orders for example.
For this, edit all parameters of Extra section. Each set of parameter is a
different chart. For several charts, duplicate section changing the number.
Note: Each Extra section reduces AWStats speed by 8%.
WARNING: A wrong setup of Extra section might result in too large arrays
that will consume all your memory, making AWStats unusable after several
updates, so be sure to setup it correctly.
In most cases, you don't need this feature.
ExtraSectionNameX is title of your personalized chart.
ExtraSectionConditionalX are conditions on URL and/or QUERY_STRING and/or
REFERER you can use to count or not the hit. Use "|" for "OR".
ExtraSectionFirstColumnTitleX is the first column title of the chart.
ExtraSectionFirstColumnValuesX is a Regex string to tell AWStats how to
extract the value used for first column. Each different value found will
be a different row. Be sure that list of different values is "limited" to
avoid "not enough memory" problems !
ExtraSectionFirstColumnFormatX is the string used to write value.
ExtraSectionStatTypesX are things you want to count. You can use standard
code letters (P for pages,H for hits,B for bandwidth,L for last access).
ExtraSectionAddAverageRowX add a row at bottom of chart with average values.
ExtraSectionAddSumRowX add a row at bottom of chart with sum values.
MaxNbOfExtraX is maximum number of rows shown in chart.
MinHitExtraX is minimum number of hits required to be shown in chart.
You will find here examples of ExtraSection setup you can follow to build your own reports:
Image your web site is an e-store that sells 80 different products. Each of them has an id.
Each time, someone make an order for product 49, the order.cgi script is called with in URL
query parameter the id of the product, so you get in your log file a hit that looks like this: GET /cgi-bin/order.cgi?productid=49&session=A0B1C2
So this is an example on how to setup your ExtraSection, to track your product orders:
ExtraSectionName1="Product orders"
ExtraSectionCondition1="URL,/cgi-bin/order.cgi"
ExtraSectionFirstColumnTitle1="Product ID"
ExtraSectionFirstColumnValues1="QUERY_STRING,productid=([^&]+)"
ExtraSectionFirstColumnFormat1="%s"
ExtraSectionStatTypes1=PL
ExtraSectionAddAverageRow1=0
ExtraSectionAddSumRow1=1
MaxNbOfExtra1=100
MinHitExtra1=1
This is an example on how to setup your ExtraSection:
ExtraSectionName1="Bugzilla: Most frequently viewed bugs"
ExtraSectionCondition1="URL,/bugzilla/show_bug.cgi"
ExtraSectionFirstColumnTitle1="Bug ID"
ExtraSectionFirstColumnValues1="QUERY_STRING,id=([^&]+)"
ExtraSectionFirstColumnFormat1="<a href='/bugzilla/show_bug.cgi?id=%s' target=new>%s</a>"
ExtraSectionStatTypes1=PL
ExtraSectionAddAverageRow=0
ExtraSectionAddSumRow=1
MaxNbOfExtra1=500
MinHitExtra1=1