Dynamic image loading in jsp
I need to load the dynamic images in jsp, where images are stroing outside the application server not part of deployment, images are placed on some folder in linux server.
I will get the path of the image from the database and i need to fetch the images from the mentioned path and load the images in jsp using custom tags.
Thanks for the solution in advance.
Ramakrishna K M
Re: Dynamic image loading in jsp
I tried using the above code to refresh an image in my webpage. It does not work. It loads the image only once and stays put. Am I doing something wrong? Could someone kindly help me?
<%@ page import="java.util.*" %>
<%@ page import="java.util.Calendar" %>
<%@ page import="java.io.File" %>
<%@ page import="java.io.*" %>
<%@ page language="java" import="java.util.*"%>
<img src="C:\\WebDev\\uploads\\image\\image.jpg" border="1" name="track">
image = "C:\\WebDev\\uploads\\image\\image.jpg"
document.images["track"].src = image;
There will be an image, say image.jpg at a fixed location in the server. It will be overwritten by another program over and over again. I want the webpage to keep loading that same image again and again so that the client can see the progress. I have managed to refresh the page automatically, but that is not what I want to do. I just want the image to refresh.