vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=113)
-   -   vBMicrostats (https://vborg.vbsupport.ru/showthread.php?t=116027)

DementedMindz 05-19-2006 05:17 AM

here is what i mean if i remove the admin table the alt1 it groups both lines into one...

TECK 05-19-2006 05:19 AM

Bob, post here the actual html code from the page source, not footer template. Start from the beginning of microstats code to the end of footer.
I will fix it, something is wrong with the row colspan, in my mod.

EasyTarget 05-19-2006 05:24 AM

working good for me, though if I view the same exact page without any changes sometimes I'll get php close to 90% and every once in awhile I'll get the sql at like 70%.

TECK 05-19-2006 05:30 AM

Quote:

Originally Posted by DementedMindz
here is my screen shot so far of what i have going on... just tryin to figure out the admin table now

Patience, you are almost there ... :)
First segment of code is ok, but try this instead.
Find:
Code:

        $ms_output .= '                <span class="smallfont">Page generated in ' . $total_time . ' seconds (' . $php_percent . ' - ' . $sql_percent . ') with ' . $query_count . ' queries</span>' . "\n";
Replace it with:
Code:

        $ms_output .= 'Page generated in ' . $total_time . ' seconds (' . $php_percent . ' - ' . $sql_percent . ') with ' . $query_count . ' queries<br />';
Next, find:
Code:

                $ms_output .= '<tr align="' . $stylevar['right'] . '">' . "\n";
                $ms_output .= '        <td class="alt1"' . iif($show['quickchooser'] OR $show['languagechooser'], ' colspan="' . $colspan . '"') . '>' . "\n";
                $ms_output .= '                <span class="smallfont">' . $memory_status . $debug_status . $gzip_status . $server_status . $templates_status . '</span>' . "\n";
                $ms_output .= '        </td>' . "\n";
                $ms_output .= '</tr>' . "\n";

Replace it with:
Code:

$ms_output .= $memory_status . $debug_status . $gzip_status . $server_status . $templates_status;
Then, use this code in your footer template:
Code:

        $vbphrase[powered_by_vbulletin]<if condition="$show['microstats']"><br />
        {microstats}</if>


Mr Chad 05-19-2006 05:34 AM

Quote:

Originally Posted by TECK
Patience, you are almost there ... :)
First segment of code is ok, but try this instead.
Find:
Code:

        $ms_output .= '                <span class="smallfont">Page generated in ' . $total_time . ' seconds (' . $php_percent . ' - ' . $sql_percent . ') with ' . $query_count . ' queries</span>' . "\n";
Replace it with:
Code:

        $ms_output .= 'Page generated in ' . $total_time . ' seconds (' . $php_percent . ' - ' . $sql_percent . ') with ' . $query_count . ' queries<br />';
Next, find:
Code:

                $ms_output .= '<tr align="' . $stylevar['right'] . '">' . "\n";
                $ms_output .= '        <td class="alt1"' . iif($show['quickchooser'] OR $show['languagechooser'], ' colspan="' . $colspan . '"') . '>' . "\n";
                $ms_output .= '                <span class="smallfont">' . $memory_status . $debug_status . $gzip_status . $server_status . $templates_status . '</span>' . "\n";
                $ms_output .= '        </td>' . "\n";
                $ms_output .= '</tr>' . "\n";

Replace it with:
Code:

$ms_output .= $memory_status . $debug_status . $gzip_status . $server_status . $templates_status;
Then, use this code in your footer template:
Code:

        $vbphrase[powered_by_vbulletin]<if condition="$show['microstats']"><br />
        {microstats}</if>


where are you putting this code?

DementedMindz 05-19-2006 05:35 AM

lol i just got it before i refreshed the page lol thank you very much here is my code in my vBMicroStats Global Hook if anyone wants it like this hope you dont mind if so ill remove it.... just remember members only see the top code not the bottom one...

also i placed my <if condition="$show['microstats']">{microstats}</if> in the copyright part of the footer like this

Code:

<div align="center">
        <div class="smallfont" align="center">
        <!-- Do not remove this copyright notice -->
<br />
        $vbphrase[powered_by_vbulletin]       
        <br />
<!-- Do not remove this copyright notice -->
</div>
       
        <div class="smallfont" align="center">
        <!-- Do not remove $cronimage or your scheduled tasks will cease to function -->
        $cronimage
        <!-- Do not remove $cronimage or your scheduled tasks will cease to function -->
       
        $vboptions[copyrighttext]
<if condition="$show['microstats']">{microstats}</if>
        </div>
</div>


TECK 05-19-2006 05:39 AM

Quote:

Originally Posted by EasyTarget
working good for me, though if I view the same exact page without any changes sometimes I'll get php close to 90% and every once in awhile I'll get the sql at like 70%.

Something is wrong with a mod installed, probably. :)
MySQL is a very smart language. If you run a query for the first time, it will execute it and also store it in the memory, in case you will need to perform it again. That saves server resources.
If you don't use it for a certain period of time, the process is dumped automatically.

This is where you see the critical points in your PHP pages. If every time you load a new page that have wierd mods enabled, MicroStats will warn you with the actual results, creating rightaway a question mark in your mind about the quality of the code you installed.

The best way to see what are the "clean" results of your PHP/MySQL code is to install MicroStats into an unmodded vBulletin test board. Then you can compare the clean results with your board results...

TECK 05-19-2006 05:41 AM

Quote:

Originally Posted by DementedMindz
just remember members only see the top code not the bottom one...

Hmm 24 queries? That's a lot! vBulletin have only 9 queries on the main page.
Watch the server load, it's close to the sky. The bold numbers should not be higher then 1.00, yours are over 3.00.
Are you on a shared server? If you are, contact your host and let them know.
Someone is eating a lot of CPU there...

DementedMindz 05-19-2006 05:43 AM

lol im doing a backup thats why... but the queries you are seeing is from my vbadvanced page...

TECK 05-19-2006 05:44 AM

Quote:

Originally Posted by Mr Chad
where are you putting this code?

The $ms_output code you place it into your vBMicroStats Global Hook plugin.
The second, into your footer template, or any other template you like. ;)


All times are GMT. The time now is 02:11 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.02611 seconds
  • Memory Usage 1,755KB
  • 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
  • (11)bbcode_code_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (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