File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how detect a location of any *.jsp?

 
dar
Ranch Hand
Posts: 45
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, all.
I have any *.jsp file in address TOMCAT_HOME/webapps/jsplocation/test.jsp.
I need to get a full path of this *.jsp at run-time.
I tried these ways (methods), but without success.

I need to get "TOMCAT_HOME/webapps/jsplocation/test.jsp" or "TOMCAT_HOME/webapps/jsplocation/".
How can I do it?
Please, any idea...
Thank You for your answer.
[ October 11, 2002: Message edited by: dajac chison ]
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64177
83
IntelliJ IDE Java jQuery Mac Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check out ServletContext.getRealPath
hth,
bear
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic