vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=236)
-   -   Board Optimization - Forum Load Time Indicator (https://vborg.vbsupport.ru/showthread.php?t=198078)

UKBusinessLive 12-04-2008 10:00 PM

Forum Load Time Indicator
 
1 Attachment(s)
Ever wanted to see just how fast your board is loading?? Its a bit slow but your not sure how slow?? Just loaded a new hack - Is your board just as fast???

Well now you'll know with this simple little hack that sits queitly at the bottom of your footer. A timer starts when the page begins to parse and ends when it has completed loading all of the content. The result is the time in seconds of how fast (or slow) your forums are loading.

The Instructions are so simple too :D

ACP> Style Manager > Your Forum Style

1. Copy the code below into your forum's style headerinclude.

Code:

<script type="text/javascript">
<!-- Begin
/* This script and many more are available free online at
The JavaScript Source!! http://javascript.internet.com
Created by: Abraham Joffe :: http://www.abrahamjoffe.com.au/ */

var startTime=new Date();

function currentTime(){
  var a=Math.floor((new Date()-startTime)/100)/10;
  if (a%1==0) a+=".0";
  document.getElementById("endTime").innerHTML=a;
}

window.onload=function(){
  clearTimeout(loopTime);
}

// End -->
</script>

and post this code into the Footer

Code:

<div align="center">
<script type="text/javascript">
<!-- Begin
  document.write('This Page took <span id="endTime">0.0</span> seconds to load.');
  var loopTime=setInterval("currentTime()",100);
// End -->
</script>
</div>

Thats it, short, and sweet enjoy :p

Please Click install if you use this ;)

Original Script Created by : Abraham Joffe

UKBusinessLive 12-05-2008 03:22 PM

Reserved :p

Infopro 12-05-2008 07:27 PM

The first piece if you use this, should go into the headerinclude. In the div for the footer if you added a class="smallfont" it looks a bit nicer. ;)

cbiweb 12-05-2008 10:40 PM

Nice job! (and agrees with Infopro)

*Installed*

UKBusinessLive 12-06-2008 05:25 AM

Quote:

Originally Posted by Infopro (Post 1679244)
The first piece if you use this, should go into the headerinclude. In the div for the footer if you added a class="smallfont" it looks a bit nicer. ;)

Thanks for the tip ;)

Infopro 12-06-2008 05:44 PM

Here's one more, there's more than one way to skin a cat:
http://us2.php.net/microtime ;)

punchbowl 12-06-2008 06:12 PM

Why remove the original coders credit? The code was free anyway.

http://javascript.internet.com/text-...indicator.html

Bounce 12-06-2008 08:07 PM

MY "timer" keeps going and going lol :eek:

vietfancy 12-07-2008 02:55 AM

Quote:

Originally Posted by hIBEES (Post 1679829)
MY "timer" keeps going and going lol :eek:

hahaha you made me laugh, dude.

UKBusinessLive 12-07-2008 06:22 AM

Quote:

Originally Posted by punchbowl (Post 1679751)
Why remove the original coders credit? The code was free anyway.

http://javascript.internet.com/text-...indicator.html

Thanks Punchbowl :D

i was sent the code by one of my members without any mention of author or copyright attached to it, I will now add it to the main post.

Why is it that you say i removed the original credit to the author??? In my Snowflake mod i give the author all the credit. Had i known about this one i would of done the same.

Some people don't half jump to conclusions :rolleyes:


All times are GMT. The time now is 07:41 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01065 seconds
  • Memory Usage 1,738KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete