Welcome to WebmasterWorld Guest from 220.127.116.11 , register , free tools , login , search , pro membership , help , library , announcements , recent posts , open posts Become a Pro Member
Deal with Image not Found Need classic ASP code iloveu msg:948371 2:41 am on Dec 14, 2005 (gmt 0) I run a site with classic ASP. One situation is: when a visitor clicks a page with broken image link (no image file at all), the ASP code is able to detect it, and display a "Picture Not Found" or "Picture coming soon" image instead.
IF the picture not exists THEN
disply a image of "Picture coming soon" ELSE 'just show the picture EMD IF
Do you know how to write this code with classic ASP?
Krapulator msg:948372 1:35 am on Dec 15, 2005 (gmt 0)
A possible solution would be to create an ASP page which displays an image based on a url parameter.
EG something like:
then in the code on your view-image.asp page, you could use the filesystem object to test whether the image exists on the server and then show it if it exists and show an alternate if it doesn't.
duckhunter msg:948373 3:58 pm on Dec 16, 2005 (gmt 0)
Use the XMLHttp object to open the image's URL. If object.status = 200, it's there.
(Kinda expensive operation to do everytime someone hits the page tho)