This is probably the easiest thing I have looked at all day.
First, make sure you have a 1px transparent image. I am also
assuming that you are calling your images from a file and that the
name is being pulled by a recordset from a name in your database
and that the code loops until EOF. If so, use the following code
block where your image recordset is:
Now, I know you are probably asking, "What are we doing?"
- First we are declaring a Variable and naming it PicShow .
- Next we give PicShow a value equal to the contents of
- We then start our IF THEN routine by saying that IF the
contents of PicShow is not empty (<> -- not equal to "" --
empty) THEN we must execute the next line of code. Which happens to
be <img src="<%=PicShow%>"> (remember that PicShow now
holds the value of the image path)
- So what happens if PicShow IS empty? That's where the ELSE
comes in with ELSE execute the next line of code. Which happens to
be a standard HTML image path to our default image " <img
- END IF tells the page that this particular IF THEN routine
In short ........... IF the dynamic picture field is not
empty THEN display the dynamic picture, otherwise ELSE display a
standard static picture.
Let me know if this is clear or not. Good luck and keep