You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Ludovic Maitre <Lu...@sophia.inria.fr> on 2001/07/27 16:14:35 UTC

Re: Default folder in Tomcat

hello,

you can obtain the path where your application is located with the
following function :
WEBAPP_ROOT = getServletConfig().getServletContext().getRealPath()
this is obtained from the sample file realpath.jsp, that i sugger you
read.
After obtaining the location of your webapp, simply add WEB-INF + the
name of the property file.

mili@ibsplc.com wrote:
> 
> Hello,
> 
> I am using Tomcat for the first time, I have a doubt, can someone help
> me with that please.
> 
> I am refering to some properties files from my Bean.
> I do not want to hardcode the path in my code.
> Can someone plesae tell me the default folder
> that the server reads from. I tried putting my files
> in my webapps folder , it doesnt seem to work.
> 
> Thanks in advance.
> regs
> M

-- 
 Ludovic.Maitre@sophia.inria.fr

 INRIA - 2004 route des lucioles - BP 93    Tel: (33/0) 4 92 38 50 41
 06902   SOPHIA-ANTIPOLIS cedex (France)    Fax: (33/0) 4 92 38 76 02