How to use image source from tmp folder of ubuntu

1

0

I have a jsp web application running on Ubuntu apache server. I take screen shot of different picture and save those in tmp folder of the server. Now I need to show this picture in my web application. How can I show picture in my application from tmp folder?

when I set image source src="/tmp/zzz.png" is not working.

tetrapack

Posted 2013-07-13T14:31:03.163

Reputation: 71

You need to make /tmp accessible to apache. Is saving the screenshot somewhere else an option? – terdon – 2013-07-13T14:49:58.343

Is there any way to move this picture from tmp folder to my web application folder programmtically? – tetrapack – 2013-07-13T15:44:34.383

Can't you chose where the screenshot is saved? – terdon – 2013-07-13T19:31:20.493

yes , I can choose the location like I could save my location like /var/lib/tomcat6/data/images folder but when I save /var/lib/tomcat6/data/images in this location it did not saved. I dont know the problem but I can save in /tmp/ folder. – tetrapack – 2013-07-13T22:44:43.420

Answers

1

I'm not sure if its the correct way of doing this but it works.

You simply make a symbolic link

ln -S /tmp /your/project/directory

for the /tmp directory inside your project and you can use it like a normal image inside a directory.

Hope this helps

paudel

Posted 2013-07-13T14:31:03.163

Reputation: 119