I'v really stuck with an issue. I have done a web program using struts framework. I have a plugin class there for which i have to pass a configuration file as parameter. That file is in webapps/Myapp/WEB-INF/ directory. So i mentioned relative path as ../webapps/Myapp/WEB-INF/conf.xml. it works fine if i download tomcat zip file & extract it & use. Bt if i download a .exe file (eg: Apache-tomcat-5.5.15.exe) & run it to install & use it, struts doesnt get that path.
I'm really stuck with this prob. i need a way to specify path which works for both tomcat installations.
Please help me to solve this prob.
Note:
I thought to check where a file creates if i create a file from my program. When the tomcat.zip is used i found the created test file is in bin directory of tomcat. That means tomcat defaultly points to bin directory, so the path to the config file ../webapps/Myapp/WEB-INF/conf.xml. works fine.
When i used tomcat.exe & installed tomcat in my machine & run the program,i found that the test file i created in my code level was in windows/system32/ directory. so in this case tomcat doesnt defaultly points to the bin directory i guess.
hope this helps to give me a good answer.
Thanks in advance.
Please do not post the same question more than once. It causes confusion and duplication of effort as the community tries to help everyone.
CarefullyChooseOneForum