mod_usertrack.html revision d28e32b1bddce6e4ca3d8c305e265d6f76275b68
2521N/A<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
2521N/A<HTML>
2521N/A<HEAD>
2521N/A<TITLE>Apache module mod_usertrack</TITLE>
2521N/A</HEAD>
2521N/A
2521N/A<BODY>
2521N/A<!--#include virtual="header.html" -->
2521N/A<H1>Module mod_usertrack</h1>
2521N/A
2521N/APrevious releases of Apache have included a module which generates a
2521N/A'clickstream' log of user activity on a site, using cookies. This was
2521N/Acalled the "cookies" module, mod_cookies. In Apache 1.2 and later, this module
2521N/Ahas
2521N/Abeen renamed the "user tracking" module, mod_usertrack. This module
2521N/Ahas been
2521N/Asimplified and new directives added.
2521N/A
2521N/A<hr>
2521N/A
2521N/A<h2>Logging</h2>
2521N/A
5403N/APreviously, the cookies module (now the user tracking module) did its
2521N/Aown logging, using the <tt>CookieLog</tt> directive. In this release,
3998N/Athis module does no logging at all. Instead, a configurable log
2521N/Aformat file should be used to log user click-streams. This is possible
2521N/Abecause the logging module now allows <a
2521N/Ahref="/multilogs.html">multiple log files</a>. The cookie itself is
5403N/Alogged by using the text <tt>%{cookie}n </tt>
2521N/A
2521N/Ain the log file format. For example:
2521N/A<pre>
5403N/ACustomLog logs/clickstream "%{cookie}i %r %t"
2521N/A</pre>
2521N/A
2521N/AFor backward compatibility the configurable log module implements the
2521N/Aold <tt>CookieLog</tt> directive, but this should be upgrade to the
5403N/Aabove <tt>CustomLog</tt> directive.
2899N/A
3998N/A<h2>Directives</h2>
4982N/A
2820N/A<ul>
3817N/A<li><a href="#cookieexpires">CookieExpires</a>
3817N/A<li><a href="#cookietracking">CookieTracking</a>
3817N/A</ul>
2521N/A
2521N/A<hr>
2521N/A
2521N/A<a name="cookieexpires"><h2>CookieExpires</h2></A>
2521N/A<strong>Syntax:</strong> CookieExpires <em>expiry-period</em><br>
2521N/A<strong>Context:</strong> server config, virtual host<br>
2521N/A<strong>Status:</strong> optional<br>
2521N/A<strong>Module:</strong> mod_usertrack<p>
2521N/A
2521N/AWhen used, this directive sets an expiry time on the cookie generated
2521N/Aby the usertrack module. The <i>expiry-period</i> can be given either
2521N/Aas a number of seconds, or in the format such as "2 weeks 3 days 7
2521N/Ahours". Valid denominations are: years, months, weeks, hours, minutes
2521N/Aand seconds.
2521N/A
2521N/A<p>If this directive is not used, cookies last only for the current
2521N/Abrowser session.</p>
4337N/A
4337N/A<a name="cookietracking"><h2>CookieTracking</h2></A>
<strong>Syntax:</strong> CookieTracking <em>on | off</em><br>
<strong>Context:</strong> server config, virtual host, directory,
.htaccess<br>
<strong>Override:</strong> FileInfo<br>
<strong>Status:</strong> optional<br>
<strong>Module:</strong> mod_usertrack<p>
When the user track module is compiled in, and "CookieTracking on" is
set, Apache will start sending a user-tracking cookie for all new
requests. This directive can be used to turn this behavior on or off
on a per-server or per-directory basis. By default, compiling
mod_usertrack will not activate cookies.
<!--#include virtual="footer.html" -->
</BODY>
</HTML>