View Single Post
Old 10-26-2006, 10:36 AM   #1 (permalink)
alecks
Inactive
 
Join Date: 10-26-06
Posts: 3
iTrader: 0 / 0%
Latest Blog:
None

alecks is liked by many
Force Caching of Images but not the page (asp)

Hello,

I've been researching this all week and haven't found a good solution.
I run a website where artists can upload their artwork and add it to a huge collaborative piece (www.cre18.com/canvas.asp).

The site is dynamically driven; uses asp to get submited cells and renders them to the page. the images are file based (not stored in the DB).

How can I force caching metadata or headers on IMAGES ONLY, but not the page that serves the images (art.asp)
if I put caching headers on art.asp, then it won't load new images as they are submitted.

I just want to force all the art images (say 1_1.jpg, 1_2.jpg, etc...) to be cached longer

I thought about writing an image serving script that reads each file and does a binary write. Something like :
instead of <img src="art/1_1.jpg">
do: <img src="getimg.asp?1_1.jpg">
and set the headers on getimg.asp, but would this round-about method be slower or cause too much overhead, whith all those FileSystemObjects loading up

Any thoughts would be greatly appreciated.

Thanks
-Alex
alecks is offline   Reply With Quote
Sponsored Links
SEO Hosting by HostGator  Advertise Here  Buy Blog Links