Search code examples
javascripthtmlprogress-barloadingprogress

how display any content in browser during page loading


In my html code a lot of time leaves on loading of the script blocks.

While there is a loading on the screen of the browser nothing is displayed (white screen).

How can I make sure that when you start the browser would display any div block instantly (I want to make loading animation)


Solution

  • try this....

    $(window).load(function() {
      $('#loading').hide();
    });