Web Servers on Unix and Linux - Apache Api to write to "access_log"

This is Interesting: Free IT Magazines  
Home > Archive > Web Servers on Unix and Linux > August 2004 > Apache Api to write to "access_log"





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Apache Api to write to "access_log"
Audi

2004-08-08, 5:49 pm

Hi,
I write a module with Apache Api.
I used ap_log_printf. It write the message to the "error_log" file
of apache.
Which Api should I use (or any setting to use) in order to write the
message to "access_log" file?
appreciate your help ...

O.
Joshua Slive

2004-08-08, 5:49 pm

Audi wrote:
> Hi,
> I write a module with Apache Api.
> I used ap_log_printf. It write the message to the "error_log" file
> of apache.
> Which Api should I use (or any setting to use) in order to write the
> message to "access_log" file?
> appreciate your help ...


You shouldn't be writing directly to the access_log. You can provide
variables which users can choose to include. An easy way to do this is
to put the info in an apache "note", which can log using %{foobar}n in
their logformat.

Alternatively, you can see how mod_logio provides extra fields for the
access log.

Joshua.

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com