In response to Mel Martinez... Basically what I am trying to do is build a web counter that is session aware. I want to write a log file with request page, referring page, date, time, user agent and session id. I am currently using apache to sent all requests to my servlet with RewriteRule ^(.*)/(.*) http://win2k:9090/servlet/redirect?To=/$2 [R,L] so my servlet gets the parameter To and knows what page the user requested. There are only two problems with my implementation so far (aside from the fact I have not started the session tracking) first is serving the page to the visitor. I have managed this with requestdispatcher but that caused the second problem tomcat does not then rewrite the links. I just tried response.sendRedirect("http://win2k/index.html"); but that does not work with my rewrite rule as the page is redirected back to the servlet. I was informed that this would not happen with RequestDispatcher. I am about to look in to the servlet mapping, but would that allow me to preserve the identity of the requested page like the apache rewrite rule does? Could I possibly use HttpUtils() getRequestURL(HttpServletRequest req) to do what I am after? Failing that I am thinking of manually opening the file and writing it out to the visitor - would that work?? The other option I can think of is to turn all the HTML pages in to JSP and have the JSP collect the information (request page, referring page, date, time, user agent and session id) and send it to a servlet - would that be a better way of doing it? Thanks for any help Mike -_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_- Michael Tickle Computing Science Dept. of Computation ICQ 5252 8934 Mob: 0777 968 5548 Fax: 0870 705 8382 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]