how to get transform a local image to a web accessable image
- by hguser
Hi:
Generally,if we want to display a image in the web page,we give the uri of the image resource like: http://host:port/image/xxx.jpg.
Now,there are some images in my file system,and I save its absolute path in the db.
Like this;
id name address image
1 xxxx xxxx C:/images/xxx.jpg
Now if the entity is retrived,its image should be displayed in the page.
How to make it?
What I thought is copy the image under the web server dir,then build its url,then the page can render it. But I wonder if this is a good idea? Is there any other way?