vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Microstats (only for admin) - load times, server loads, queries, uncached templates! (https://vborg.vbsupport.ru/showthread.php?t=59700)

zachlee 03-05-2005 11:35 PM

is there a way to incorporate this hack, to also include a line from admincp page?

I would like it to call the function that looks up info such as:

8 Users Online (1 members and 7 guests)

which normally is located after the server load average info.

Thanks!
-Zach

neocorteqz 03-05-2005 11:53 PM

Quote:

Originally Posted by zachlee
is there a way to incorporate this hack, to also include a line from admincp page?

I would like it to call the function that looks up info such as:

8 Users Online (1 members and 7 guests)

which normally is located after the server load average info.

Thanks!
-Zach

That is already on forum home. Located within the logged in users.

But I'm sure someone knows how to add it.

Erwin 03-06-2005 08:53 PM

Quote:

Originally Posted by zachlee
is there a way to incorporate this hack, to also include a line from admincp page?

I would like it to call the function that looks up info such as:

8 Users Online (1 members and 7 guests)

which normally is located after the server load average info.

Thanks!
-Zach

Different hack - I also wrote that one - check in my profile to show this on every page.

kcadd 03-09-2005 04:59 PM

[high]* kcadd clicks install :D[/high]

sapper6fd 03-14-2005 05:37 AM

Stats for index.php with CMPS 1.0.1

Page generated in 0.21693 seconds with 23 queries (2 queries for uncached templates) [Server Loads: 3.89 1.83 : 1.59]
Uncached templates: adv_portal_latesttopicbits (5)
Uncached templates: adv_portal_latesttopics (1)

WOW.... How do I cut that back? How do I tell what pages arnt cached, and how do I cache them? BTW, thats with 3 people on the forum, shared server.

neocorteqz 03-14-2005 06:30 AM

Quote:

Originally Posted by sapper6fd
Stats for index.php with CMPS 1.0.1

Page generated in 0.21693 seconds with 23 queries (2 queries for uncached templates) [Server Loads: 3.89 1.83 : 1.59]
Uncached templates: adv_portal_latesttopicbits (5)
Uncached templates: adv_portal_latesttopics (1)

WOW.... How do I cut that back? How do I tell what pages arnt cached, and how do I cache them? BTW, thats with 3 people on the forum, shared server.


Ouch

And you can tell what is uncached by looking at your post.

Uncached templates: adv_portal_latesttopicbits (5)
Uncached templates: adv_portal_latesttopics (1)

sapper6fd 03-14-2005 02:38 PM

Quote:

Originally Posted by neocorteqz
Ouch

And you can tell what is uncached by looking at your post.

Uncached templates: adv_portal_latesttopicbits (5)
Uncached templates: adv_portal_latesttopics (1)

Well I got those quiries, but what about the other 21

neocorteqz 03-14-2005 05:10 PM

Quote:

Originally Posted by sapper6fd
Well I got those quiries, but what about the other 21

The other 21 are those two plus what ever else you have loaded on the vBadvanced portal.

The only way to cut portal queries is to get rid of some of the content.

it's best to ask this question in the vBadvanced thread.

KW802 03-14-2005 06:26 PM

Quote:

Originally Posted by sapper6fd
Uncached templates: adv_portal_latesttopicbits (5)
Uncached templates: adv_portal_latesttopics (1)

Check your changes to your global.php file. ;)

neocorteqz 03-14-2005 06:58 PM

Quote:

Originally Posted by KW802
Check your changes to your global.php file. ;)

Besides that he wants to cut back the amount of queries on that page.

Now If I read that right, if he caches those two he'll save 6?

KW802 03-14-2005 07:09 PM

Quote:

Originally Posted by neocorteqz
Besides that he wants to cut back the amount of queries on that page.

Now If I read that right, if he caches those two he'll save 6?

He should. In this case the 'latesttopics' is comprised of several 'latesttopicsbits' so his net effect should be 6 like you said.

Cyricx 03-15-2005 06:07 PM

Moved to a new host and I am having some terrible page load times.

Added in this hack to try to locate the source and the page load times are coming up whacky.

I expected 2.0 - 3.0 but I'm not even getting a .

Bug? :)

Was hoping to use this to get some hard numbers to throw at them ;)

Erwin 03-15-2005 08:03 PM

Quote:

Originally Posted by Cyricx
Moved to a new host and I am having some terrible page load times.

Added in this hack to try to locate the source and the page load times are coming up whacky.

I expected 2.0 - 3.0 but I'm not even getting a .

Bug? :)

Was hoping to use this to get some hard numbers to throw at them ;)

Ask your host. ;)

Cyricx 03-15-2005 08:06 PM

Hehe so it's totally on their side :)

The pages are loading in 10-30 seconds. I wasn't sure if that stall was causing a bug in the hacks code or something :)

I figure it's prolly supposed to be 5.6xxx seconds.

Thats Erwin, great hack and gives me something to gripe at them with some hard numbers :)

MentaL 03-15-2005 09:51 PM

thanks

Quote:

Page generated in 0.17211 seconds with 8 queries [Server Loads: 0.57 ? 0.92 : 0.83]
MentaL
www.ragezone.com

GoWo 03-20-2005 01:34 AM

Is there any reason I get this error message after installing this hack?

PHP Code:

Parse errorparse errorunexpected T_CONSTANT_ENCAPSED_STRING in /home/********/********/includes/functions.php on line 2044 


I saw that editing the functions.php file in Dreamweaver doesn't work, si I have used Notepad and Kate.

Tried copy and pasting - no joy.
Tried typing out entire hack - no joy.

Any ideas?

lasto 03-29-2005 11:37 PM

just installed on 3.0.7 works fine

Reeve of shinra 05-05-2005 04:12 AM

I was wondering if it would be possible to display slow queries as well? I like to keep an eye on that stuff and since its visable only to admins, I dont think that would add much of a hit, no?

Kaishi 05-10-2005 03:56 AM

for some reason, i installed, had it working fine on 3.07. then after a certain hack, forgot which. i stopped seeing the server loads. only queries and load time. ?_?

edit: nvm, used the older version and started working again. no idea why, anyone wanna enlighten me?

buro9 06-15-2005 04:33 AM

Nice and strange one this.

I've installed an SSL certificate on my site and am encouraging users to use SSL'd access to the forum (as it's harder for companies to block, keeps their cookies and requests secret, and prevents referer info being sent to third party sites).

Now when I surf on https:// , the 1.2 version fails. Yet when I surf http:// the 1.0 version works.

What I've done is to combine both.

If 1.2 works it uses it, otherwise it rolls over to the 1.0 version.

Strange, interesting... fixed :)

Snort_2005 06-19-2005 01:43 PM

*clicks install*

d2sector 06-25-2005 03:27 AM

How can you choose where the stats show up on your forums?

Pixelrift_will 07-13-2005 01:05 PM

installed =D

derekivey 07-14-2005 06:04 PM

Sweet going to install it now :D

Roms 07-22-2005 11:55 PM

Thanks Erwin.

faast 08-22-2005 09:41 PM

Code:

  // Microstats hack
if ($bbuserinfo[usergroupid]==6) {
                $pageendtime = microtime();
                $starttime = explode(' ', $pagestarttime);
                $endtime = explode(' ', $pageendtime);
                $totaltime = vb_number_format($endtime[0] - $starttime[0] + $endtime[1] - $starttime[1], 5);
                $loadavg = @file_get_contents("/proc/loadavg");
                if ($loadavg) {
                        $regs = explode(" ",$loadavg);
                        $serverload=' [Server Loads: <b>'.$regs[0].'</b> '.$regs[1].' : '.$regs[2].']';
                }
                $debughtml = "<center><span class=\"smallfont\">Page generated in <b>$totaltime</b> seconds with <b>$query_count</b> queries" . iif($_TEMPLATEQUERIES, " (<b>" . sizeof($_TEMPLATEQUERIES) . "</b> queries for uncached templates)", '') . "$serverload</span></center>";
    ksort($tempusagecache);
    foreach ($tempusagecache AS $tempname => $times)
    {
    if ($_TEMPLATEQUERIES["$tempname"]) $debughtml .= "<center><span class=\"smallfont\">Uncached templates: <font color=\"red\"><b>$tempname</b></font> ($times)</span></center>";
    }
                $vartext = str_replace('</body>', "$debughtml\n</body>", $vartext);

}

//Microstats Hack


I'm not a coder by any means, but if I remove the above (in red) will that show to all users? Thanks. What I mean is, is the above code workable or will it do something horribly wrong?

derekivey 08-23-2005 03:22 AM

Yes, if you remove that it will show to all users...

NJTy180 10-14-2005 11:25 PM

Quote:

Originally Posted by GoWo
Is there any reason I get this error message after installing this hack?

PHP Code:

Parse errorparse errorunexpected T_CONSTANT_ENCAPSED_STRING in /home/********/********/includes/functions.php on line 2044 


I saw that editing the functions.php file in Dreamweaver doesn't work, si I have used Notepad and Kate.

Tried copy and pasting - no joy.
Tried typing out entire hack - no joy.

Any ideas?

I got the same error, just on line 2033, I just gave up, oh well.....

Wisch 10-21-2005 09:21 PM

Page generated in 0.08409 seconds with 9 queries

sweeeeet

David_R 02-11-2006 03:27 AM

does this exists for 3.5 version ?
we have it installed and want to upgrade from 3.0.x version of our forum to 3.5

thanks.

SCuN 03-02-2009 09:16 AM

work with 3.7?


All times are GMT. The time now is 08:12 PM.

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.01450 seconds
  • Memory Usage 1,814KB
  • 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
  • (1)bbcode_code_printable
  • (2)bbcode_php_printable
  • (11)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
  • (31)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