• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Saving image on server.

 
Ratan Pawar
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i am saving image on server.
when i run it on one m/c as client and server is same its working.
for this saving image as file in temp folder i use path as c://workplace/stud_app/jsp/temp/Filename in servlet.
but application run on cvs as server is different i could not save image.
i tried as request.grtContextPath+temp/Filename its not working.
how i get this server path to save file.
i use Eclipse to run application.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
 
Ratan Pawar
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
client and server is on same computer.
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
its not working

What does this mean? What exactly is the code doing, and how is or isn't it behaving according to your expectations? Are there any error messages?
[ February 18, 2008: Message edited by: Ulf Dittmer ]
 
Arivazhagan Arutchelvam
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You should not hardcode the file path in the servlet. If you hardcoded it, then there must be a folder structure matching your file path, must be present in the server machine.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic