Apache Reference: mod_log_config, CustomLog

CustomLog

Customized Log File Facility
Syntax: CustomLog file format [env=[!]variable]
Example: CustomLog logs/access "%h \"%r\" %s %b"
Since: Apache 1.2

This directive enables you to write a customized log file, where each log file line is formatted according to the specification given in format. If the ``env=..'' construct is appended, the writing of a line can be conditionalized through the existence or nonexistence of an environment variable (usually created by mod_setenvif or mod_rewrite based on the particular HTTP request). The options for the format match those available for the argument of the LogFormat directive. If the format argument includes any spaces (as it will in almost all cases), it should be enclosed in double quotes. Instead of an actual format string, you can also use a format nickname defined with the LogFormat directive.