In my CGI programming days I often used the cgi variable called
DOCUMENT_ROOT, which apache sets to the root of the document tree. This
was very useful because we have many virtual hosts with different
document roots. I'm trying to find a method of retrieving this variable
from a servlet. I have tomcat 4.1.27 connected to Apache using mod_jk.

A couple of sources I have found suggest using
getServletContext().getRealPath("/"). However when I try this it gives
me the location of my servlet and not of the apache server's document
tree.

Does anyone know how I can retrive this information?

Many Thanks
Dave

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to