You can use this javascript code to show how long a blogpost taking to load. A automatic timer will starts when a page begin to parse and timer will stop when that page has completed loading all content.
Here is the code and installing instruction.
Login in you blogger.com blog. Then copy and paste the code below after<head>
<script type='text/javascript'>Now find and paste this code before </body>
var d = new Date();
var starttime = d.getTime(); //Get the start time
</script>
<script type='text/javascript'>At last get a html gadget in Design>Page Elements and paste this code into any Html/ Javascript widget-
var d2 = new Date();
var endtime = d2.getTime(); //Get the end time
//Find the difference between the start and end times
var totaltime = (endtime - starttime)/1000;
//Round 2 decimal places
var result = Math.round(totaltime*100)/100;
//Output results to a "P" element
document.getElementById("loadtime").innerHTML = "Page loading time: "+ result +" seconds";
</script>
<p id="loadtime">Loading....(You may write any custom message here)</p>I wish you won't get any problem to install the codes in your blogger.com blog. If you face any problem please comment here to inform me.
Yes, its working..., but how to place the Loading text at the center of the screen (not at the widget place) and after the loading finish the text will vanish.
ReplyDeletethis is very, very, very. Thanx!
ReplyDeletethank you , there is not anywhere...
ReplyDelete