I added a basic loading div to my website that fades out once the entire page has finished loading. The code I used is simple:
$(window).load(function(){
$('#loading').fadeOut(500);
});
While this works well on all desktop browsers and Chrome on mobile, it does not function properly on the iOS5 Safari browser on my iPod 3G. The loader remains on the screen, rendering the webpage unusable.
How can I resolve this issue? I prefer not to use document.ready
as I need the action to occur only after complete page loading.