Hi Peter,

Thanks for your reply. Here are few more things in the context of the
relative path:

1.> I am gathering that "/" refers to the drive where my Tomcat is installed
on Windows.  (With file path as "/subscribers.txt" the file is created at
the root of the drive.)

2.> I am not using HTTP sessions.

regards,
Rajendra


On 3/1/07, Rajendra Sakpal <[EMAIL PROTECTED]> wrote:






On 3/1/07, Pid <[EMAIL PROTECTED]> wrote:
>
> Rajendra Sakpal wrote:
> > Hi,
> >
> > I am using TOMCAT 5.5.  I am creating a file in class that is called
> from a
> > JSP.  However, the relative path that I have specified in the class
> doesn't
> > seem to work.  The path that I have used is
> > :"/webapps/Jonathon/WEB-INF/etc/subscriber.txt".
> >
> > Can someone please let me know, what is wrong with the relative path ?
>
> >
> > thanks in advance,
> > Rajendra
> >
>
> If you start the path with a "/" then it's not relative.
>
> There are functions to help you locate resources on webapp relative
> paths.
>
> String absolutePath = servletContext.getRealPath( relativePath );
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

Reply via email to