>From: "Christopher K. St. John" <[EMAIL PROTECTED]>
>Reply-To: "A mailing list for discussion about Sun Microsystem's Java
> Servlet API Technology." <[EMAIL PROTECTED]>
>To: [EMAIL PROTECTED]
>Subject: Re: file path question in servlet
>Date: Mon, 8 Jan 2001 16:28:50 -0600
>
>Peter Smith wrote:
> >
> > Thanks Chris, it works if I gives the absolute path of the file to
> > FileReader constructor, such as
> > C:\\jakarta-tomcat\\webapps\\ROOT\\WEB-INF\\classes\\normal.xml
> >
>
> If you put the xml file and stylesheet in the root directory:
>
> C:\\jakara-tomcat\\webapps\\ROOT
>
> then you could avoid hardcoding any paths, plus you could
>(optionally) let clients who could deal with it directly
>access the xml/xsl files. If you're going to deploy the webapp
>more than one place, then avoiding hardcoded paths would make
>your life easier.
I tried put xml and xsl files in ROOT directory, and do
FileReader xmlReader = new FileReader("normal.xml");
Then I got FileNotFoundException exception.
_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html