Is it possible to preload all page contents (like showing a loading bar / animated gif.. or loading text.. ) until the contents are fully loaded and then displayed to the user/visitor ? If this is possible, can you give me just directions or resources to follow to achieve this. Because I was able to find image preloaders easily, but I am seeking for a preloading technique that will preload all content on the page before being displayed.
Share
There’s no need to use Ajax for this. Simply set the page’s wrapper div
displaytonone. Then change it toblockwhen the document is loaded.Your code might look like this, using vanilla javascript:
Update, in jQuery:
Related documents: Events/ready, Events/load, CSS/css & Core/$