Page 1 of 1
Logging PHP vars in apache
Posted: Sun Nov 06, 2005 12:52 pm
by Todd_Z
Is there anyway to put a session variable into an apache access log? I would like to log the Ip address, the referer, the date, all that stuff, and the user's session id.
Posted: Sun Nov 06, 2005 2:14 pm
by m3mn0n
Are you on a shared host or is this for an environment that you have complete root access to?
And why not use your own log file? You could easily create a SesInfoLog.log file and place the variables there.
Posted: Sun Nov 06, 2005 2:15 pm
by Todd_Z
virtual server - i have root access
Posted: Sun Nov 06, 2005 5:27 pm
by feyd
may want to look into the
error_log() function..
Posted: Sun Nov 06, 2005 6:22 pm
by Todd_Z
I mean the access logs, not the error logs - like when apache logs the ip address, filename, status code, etc - it would show the $_SESSION var
Posted: Sun Nov 06, 2005 6:43 pm
by feyd
you're going to need to build it on your own then, separate from Apache's logs...
Posted: Sun Nov 06, 2005 7:30 pm
by timvw
Posted: Sun Nov 06, 2005 9:09 pm
by Todd_Z
dont have access :-\