Re: alternative img

Discussion in 'HTML' started by Clubberboy, Jun 25, 2003.

  1. Clubberboy

    Clubberboy Guest

    David de Kloet wrote:
    > I make a dynamicaly creatated image tag and i'm not sure the image is
    > going to exist at the time someone views my homepage. Is there a way
    > to tell the browser it should show another (default) image if the
    > first one isn't available?


    If you can't do it server-side try
    <img src="good.jpg" onerror="this.src='bad.jpg'" />

    --
    http://www.techtronix.be
     
    Clubberboy, Jun 25, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. news.austin.rr.com

    how to download img from html img tag

    news.austin.rr.com, Apr 27, 2005, in forum: ASP .Net
    Replies:
    2
    Views:
    512
    Steve C. Orr [MVP, MCSD]
    Apr 27, 2005
  2. Richard

    Re: alternative img

    Richard, Jun 25, 2003, in forum: HTML
    Replies:
    1
    Views:
    932
    David de Kloet
    Jun 25, 2003
  3. Philipp Lenssen

    Problem: <img></img>

    Philipp Lenssen, Jun 27, 2005, in forum: XML
    Replies:
    15
    Views:
    764
    David Håsäther
    Jul 3, 2005
  4. Jopek
    Replies:
    7
    Views:
    403
    dorayme
    Apr 26, 2009
  5. Replies:
    7
    Views:
    181
    Tad McClellan
    Jun 22, 2006
Loading...

Share This Page