    function ImageOk(img) {   
        // Body has finished loading so if img is not complete then   
        // you  have a broken image so return false - image is not ok   
        if (!img.complete) return false;   
  
        // if naturalWidth is undefined or zero then the image failed to load   
        // so return false - image is not ok   
        if (typeof img.naturalWidth != "undefined" && img.naturalWidth == 0) return false;   
  
        // Passed all checks - image succeeded in loading - image is ok   
        return true;   
    }   
  
    function BrokenImageCheck() {   
        // Name of image to replace broken image icon with   
        var replacementImg = "/Images/Site Images/no-imagesm.gif";   
  
        // Loop through all images in the document   
        for (var i = 0; i < document.images.length; i++) {   
            // If image did not finish loading   
            if (!ImageOk(document.images[i])) {   
                document.images[i].src = replacementImg;   
                // document.images[i].style.display = "none";   
            }   
        }   
    }   
  
    // After body loads check all images to see if the sucessfully loaded   
    window.onload=BrokenImageCheck;   