• Post Reply 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

Writing dynamically inside the web application

 
Ranch Hand
Posts: 224
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Suppose, I have a web application deployed.
The application uses a map service, to generate new maps for each request.
Can the map service, write its output to a directory (Say it "output") which is parallel to WEB-INF ?

Will that (output dir) be not writable? If yes, is there any way to show the dynamically generated map (the jpg files), in the application using some url ?

Thanks
[ April 18, 2006: Message edited by: Mishra Anshu ]
 
Bartender
Posts: 1845
10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

>Can the map service, write its output to a directory (Say it "output") which is parallel to WEB-INF ?


Yes.

Will that (output dir) be not writable?


That depends upon the server setup. You need to grant permissions so that your server can write to that directory.

You could also just send the requested image to the client without saving it to disk.
Either way, to load an image onto the page, you use the <img> tag as normal in HTML.
<img src="<%= imageFileName %>">
or
<img src="ImageServlet?imageid=42">

Using a Servlet to send the image back via an output stream is a good option.
Cheers,
evnafets
 
Mishra Anshu
Ranch Hand
Posts: 224
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks,

I had tried yesterday, to change the permission on the server and it worked.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic