Howdy, This is a FAQ -- you should search the archives before posting. Instead of using a File I/O based API to read properties, use ServletContext#getResourceAsSteeam("/WEB-INF/classes/JTS.props");
Yoav Shapira Millennium ChemInformatics >-----Original Message----- >From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] >Sent: Friday, October 03, 2003 10:43 AM >To: [EMAIL PROTECTED] >Subject: Tomcat settings: Unable to access a text file .... > >Hi there, > >We were using a web application using iPlanet. Now we want to try Tomcat as >a standalone Application container for the same application. We have >migrated the application in the desired directory structure under Tomcat >directory with the apropriate changes to the application's Web.xml and the >server.xml > >The directory structure looks like this .... >Webapps/OurAPPLICATION/WEB-INF/Web.xml >Webapps/OurAPPLICATION/WEB-INF/classes/... >Webapps/OurAPPLICATION/jsp/*.jsp and *.html >Webapps/OurAPPLICATION/gif/ > >Now, i have a login.jsp that uses a java file (ReadIni.java under /classes) >to read JTS.props file. The problem is i can access this .props file if i >give the absolute path of this file but can't read the same if i just give >the name, e.g. "D:\\JTS.props" works, but "JTS.props" doesn't > >This was working fine under iPlanet as this file used to be kept under the >appropriateServer/conf file. The doubt is where do we keep it in Tomcat so >that the Tomcat server applies the appropriate context-path before the name >of the file, or what configuration setting might facilitate the same? >Any and every help is welcome.... > >Regards, >Ashish Gadre >Polaris Software Labs > This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]