• Resolved cableghost

    (@cableghost)


    I have set a background image for a div to show only when the ad in the div is blocked. Upon page loading though, the background image appears first, then the ad appears.

    I have tried the following functions, but they give me syntax errors. I would appreciate having either function cleaned up, or I would certainly try an alternative…thanks.

    function loadBG(){
        document.getElementById("id").style.backgroundImage="/images/image.png";
    }
    window.onload=loadBG();
    function show() {
        AB = document.getElementById('id');
        AB.style.display = 'inline';
    }
    setTimeout("show()", 5000);

    -Scott

  • The topic ‘Delay loading of background image’ is closed to new replies.