Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need Help

 
Ranch Hand
Posts: 48
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Hi All,
I have a webapplication that contains the some html files and images. These html files and images are the part of the build. I would like to place
these html files and images outside the webapplication build.
Let supposer
C:\StaticResources ---> Contains the HTML files and Images
C:\usr\Tomcat\webapps\webapplication --> is the path of the webapplication

So can it possible that jsp which are presented in the web-application directly points to html files and images files. I know that
by using the Java File Stream i can access the same .

Is there any support in the servlet that can directly access the same

Regards,
Maneesh Chauhan
 
Ranch Hand
Posts: 3389
Mac MySQL Database Tomcat Server
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
I think it might be possible by using the APIs and by passing the absolute URI.

But then, it is better and suggestable for portability reasons (to avoid dependencies), to keep the static (html files and images) *as a part of the web application* (Inside WAR file).

HtH.
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Duplicate of:
https://coderanch.com/t/364517/Servlets/java/context-xml-Help-Needed

Maneesh Chauahn,
Please do not ask the same question multiple times.
Doing so creates confusion and makes people less likely to want to help you.
    Bookmark Topic Watch Topic
  • New Topic