#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jan 2000
    Location
    SPAIN
    Posts
    3
    Rep Power
    0
    Is there any way to detect if the image that replaces the original has loaded correctly and failing that ignore the rest of the function?

    Thanks.
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 1999
    Location
    Helden,Limburg,The Netherlands
    Posts
    33
    Rep Power
    15
    If you preload your images you can have an environment variable be set by the body onlad event. This variable could switch from false to true and then your function to replace the image should have this statement:

    if (nameOfEnvironmentVariable) {
    // The rest of your function goes here
    }

Similar Threads

  1. Finding Images in HTML
    By beardo in forum PHP Development
    Replies: 14
    Last Post: March 28th, 2004, 06:29 AM
  2. mouse over change image in different frames
    By musher5 in forum HTML Programming
    Replies: 3
    Last Post: December 5th, 2003, 11:06 AM
  3. how to avoid image is resized by the user
    By entropia in forum PHP Development
    Replies: 7
    Last Post: July 6th, 2003, 04:24 AM
  4. Javascript image preload race condition
    By lmcccha in forum JavaScript Development
    Replies: 5
    Last Post: February 13th, 2003, 08:21 PM
  5. onmouseover on image - > launch on mouse over event on text
    By IrinaIonela in forum HTML Programming
    Replies: 1
    Last Post: May 17th, 2002, 03:18 AM

IMN logo majestic logo threadwatch logo seochat tools logo