I have 2 pages, when the second page load in first page, the JavaScript of that pages run after all the JavaScript and load very slowly. I wrote the below code to show the spinner till the second page load completely. But the spinner doesn't s work. Here is my code:
<script>
$('.tourajaxi').html('<i class="fa fa-spinner fa-pulse fa-3x fa-fw" ></i><span class="sr-only">Loading ...</span>');
$(window).load(function() {
$('.tourajaxi').load('/toursajax.bc?gid=325');
});
</script>