The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Details »» | |||||||||||||||||||||||||
For vBulletin version: 2.3.x
Files added: vbs_counter.php, vbstats.php, vbstats_admin.php, vbstats_set.php Files to edit: None! (all hacking is optional) Current Version: 230.b (02.14.03 - 3am CST) What does it do?
Check the samples: Stats http://www.talkloud.net/forums/vbstats.php Incoming Referrals http://www.talkloud.net/forums/vbsta...ction=incoming Member Referrals http://www.talkloud.net/forums/vbsta...on=memberrefer Top Posters http://www.talkloud.net/forums/vbsta...ion=topposters Top Threads/Forums http://www.talkloud.net/forums/vbsta...ion=topthreads Top Visitors Countries http://www.talkloud.net/forums/vbsta...action=country Here's the newest version, it's only been a year and a half since the last update! Translations have been removed as it just made it easy for people to get the hack even without a license. I am hoping people who make translations will be kind enough to post here. Special Note: I am about as far as it gets from a PHP guru. This is my first hack or addon or whatchamacallit. If this somehow nukes your system Im quite apologetic, but I know you will all be smart enough to BACK UP YOUR DATABASE BEFORE INSTALLING THIS.. I have faith Brad and Chen have both checked this out and given their stamps on it but that doesnt mean it will all Gel for you. Be smart, back it up. Install: There is a self install file that takes care of the templates and tables, simply unzip the package and upload it (with paths) to your vbulletin directory. Then run the install. Please be sure you add your site (yoursite.com) to the excluded urls in the CP. If you dont your site will get counted as a referrer and that can get messy. Demo: You can of course see the demo at http://www.talkloud.net/ however if you'd like to see it in use on some other boards check out vbstats page where I will try to keep a list of installs for you to check out. If you do install it please let me know so I can put your site up! I tested this on my test forum, and on one public forum, and all went well, if there are any problems you notice please report them here as soon as possible. ------- CHANGELOG [230.b] Changed Active Users to fix a small bug. [230.b] Like, tested it and stuff.. [230.a] The MySQL Row=O error is now customized to say add to the template!!!! hopefully no more "where did I go wrong?" posts! Muahahaha! [230.a] Fixed Upgrade Counter (?action=upgrade) [230.a] Set Excluded URL.. Now lists URLS [230.a] Updated Istall to be compatible with vB 2.3.0 [230.a] Changed Most Number Results to Have a , format (ie 1,000 instead of 1000) [230.a] I decided Frosted Flakes really are pretty tasty. [230.a] Implemented Kurafires Member Referrer Changes, thanks Kura [230.a] Implemented Kurafires Top Posters rewrite. DEAR GOD CHECK THE SECOND POST OF THIS THREAD BEFORE YOU ASK A QUESTION!!!! Show Your Support
|
Comments |
#1172
|
||||
|
||||
Does not show up on my FRONT PAGE!
It only works in my admin...does anyone know how to have it show on the forum home? EDIT: I added MY OWN STATISTICS link in the FOOTER template right next to "Contact Us - MYForum" links at the bottom. I am also using vbHome Lite and got errors on top of my home page, like Warning Failed vbs_counter.php or something like that. All I did to solve that problem was do what others did in this thread: Put (a copy of ) vbs_counter.php in your ROOT directory of vbHome. So that you have one inside root and the other copy inside /forum folder. That's it! |
#1173
|
||||
|
||||
I'm sorry to bother again after so many tons of posts... but I definetely need your help!
I installed the hack today on my vB 2.2.9 (licensed) Everything was OK, except the problem of showing stats on forum's front page. I followed what was indicated here: https://vborg.vbsupport.ru/showthrea...406#post201406 and installed the add-ons, and I copied vbs_counter.php in forum's root. *** No results: no stats in my homepage. *** here is the vbstats.php page: http://forum.risiko.it/vbstats.php and here the forum home page: http://forum.risiko.it below the forumlist you can find the "empty" stats area... [added at the bottom of forumhome_loggedinusers template] ThanXs for help! EDITED: I fixed everything. 1) I put $vbstats in my forumhome template, formatting as desired the vbstast_forumhome template as suggested in add-ons. 2) I had to copy all the codes contained in vbstats.php (related to stats of forumand today) to index.php (under firefly today is missing the code $todayviews!) 3) I had to put $tltoday=time()-(86400); under // Today [FireFly] as indicated in some of these 77 pages... I thank a lot Bane for the masterpiece. Great!!! (already clicked "install") Byez |
#1174
|
||||
|
||||
I only set up vbStat that was on the first entry.
I followed the "addon" instructions, but it never showed up on my forum 2.3.2. So I removed all the things that the "addon instructions" told me to do and only did what the original vbStat instructions told me to do only. Then I just went to admin control panel and clicked on vbStats, which showed up fine, looked at what page or link that was, and then edited FOOTER template for the forum and added the link to Stats there. The only thing I see now, is the the PMs or Private Messages show DOUBLE the amount there really are in my box...probably because we have TWO counters, one in root and one in forums folder. I don't know how to fix this. |
#1175
|
||||
|
||||
Bane, are you going to release a vB3 version of vBStats when the vb3 hacks are allowed or you quit?
|
#1176
|
||||
|
||||
I wonder if there's any mercy soul who can help me in the optimization of the frontpage vbstats code.
Everything is working fine ( http://forum.risiko.it ) but, since I'm a totally newbie in php and mysql programming, I'm quite sure there's a fastest way to obtain the same figures shown in my forum HP. I'm publishing below 1) index.php 2) vbstats_forumhome template I beg your pardon if i post in the wrong area. Sorry, and forgive me. Thanks much to people who can help me. 1) index.php Code:
<?php error_reporting(7); $templatesused='forumhome_birthdaybit,error_nopermission,forumhome_pmloggedin,forumhome_welcometext,forumhome_logoutcode,forumhome_newposts,forumhome_todayposts,forumhome_logincode,forumhome_loggedinuser,forumhome_loggedinusers,forumhome_lastpostby,forumhome_moderator,forumhome_forumbit_level1_nopost,forumhome_forumbit_level1_post,forumhome_forumbit_level2_nopost,forumhome_forumbit_level2_post,forumhome,forumhome_unregmessage'; $loadbirthdays=1; $loadmaxusers=1; require('./global.php'); $permissions=getpermissions(); if (!$permissions['canview']) { show_nopermission(); } //check usergroup of user to see if they can use PMs //$permissions=getpermissions($forumid); if ($enablepms==1 and $permissions['canusepm'] and $bbuserinfo['receivepm']) { $ignoreusers=""; if (trim($bbuserinfo['ignorelist'])!="") { $ignoreusers='AND fromuserid<>'.implode(' AND fromuserid<>',explode(' ', trim($bbuserinfo['ignorelist']))); } $allpm=$DB_site->query_first("SELECT COUNT(*) AS messages FROM privatemessage WHERE userid=$bbuserinfo[userid] $ignoreusers"); $newpm=$DB_site->query_first("SELECT COUNT(*) AS messages FROM privatemessage WHERE userid=$bbuserinfo[userid] AND dateline>$bbuserinfo[lastvisit] AND folderid=0 $ignoreusers"); $unreadpm=$DB_site->query_first("SELECT COUNT(*) AS messages FROM privatemessage WHERE userid=$bbuserinfo[userid] AND messageread=0 AND folderid=0 $ignoreusers"); if ($newpm['messages']==0) { $lightbulb='space'; } else { $lightbulb='sirena'; } eval("\$pminfo = \"".gettemplate('forumhome_pmloggedin')."\";"); } else { $pminfo=''; } // How Many? $numbersmembers=$DB_site->query_first('SELECT COUNT(*) AS users,MAX(userid) AS max FROM user'); $numbermembers=number_format(($numbersmembers['users']), 0, ',', '.'); $snonposters=$DB_site->query_first('SELECT COUNT(*) AS users,MAX(userid) AS max FROM user WHERE posts=0'); $nonposters=number_format(($snonposters['users']), 0, ',', '.'); $activemembers=number_format((($numbersmembers['users'])-$nonposters), 0, ',', '.'); $activityrate=number_format(($activemembers/$numbermembers/10), 2, ',', '.'); // Equate [Added Post 230.b to resolve Active Users issues] // $activemembers=number_format($activemembers); // $nonposters=number_format($nonposters); // PM Totals $totalpms = $DB_site->query_first("SELECT count(*) as pmcount FROM privatemessage"); $totalpm = number_format(($totalpms[pmcount]), 0, ',', '.'); // Staff $anum = mysql_num_rows(mysql_query("select * from user WHERE usergroupid=5 or usergroupid=6 or usergroupid=7")); // get total posts & threads $countposts=$DB_site->query_first('SELECT COUNT(*) AS posts FROM post'); $totalposts=number_format(($countposts['posts']), 0, ',', '.'); $countthreads=$DB_site->query_first('SELECT COUNT(*) AS threads FROM thread'); $totalthreads=number_format(($countthreads['threads']), 0, ',', '.'); // thread Most Viewed $top3d1=$DB_site->query("SELECT threadid, title, views FROM thread GROUP BY threadid ORDER BY views DESC LIMIT 1"); while ($top3d=$DB_site->fetch_array($top3d1)) { $top3d1views = number_format(($top3d[views]), 0, ',', '.'); $top3d1id =($top3d[threadid]); $top3d1title =($top3d[title]); $maxchars='20'; // title lenght if (strlen($top3d1title) > $maxchars) { $top3d1title = substr($top3d1title, 0, $maxchars-2) . '...'; } } // get total views $boardviews = $DB_site->query_first("SELECT SUM(views) AS threadviews FROM thread"); $totalviews = number_format(($boardviews[threadviews]), 0, ',', '.'); // get newest member $getnewestusers=$DB_site->query_first("SELECT userid,username FROM user WHERE userid=$numbersmembers[max]"); $newusername=$getnewestusers['username']; $newuserid=$getnewestusers['userid']; // if user is know, then welcome if ($bbuserinfo['userid']!=0) { $username=$bbuserinfo['username']; eval("\$welcometext = \"".gettemplate('forumhome_welcometext')."\";"); eval("\$logincode = \"".gettemplate('forumhome_logoutcode')."\";"); eval("\$newposts = \"".gettemplate('forumhome_newposts')."\";"); } else { $welcometext = ""; eval("\$newposts = \"".gettemplate('forumhome_todayposts')."\";"); eval("\$logincode = \"".gettemplate('forumhome_logincode')."\";"); } $birthdaybits=""; if ($showbirthdays) { $birthdays = gettemplate('birthdays',0,0); $btoday = explode('|||',$birthdays); $today = vbdate("Y-m-d",time()); if (($today != $btoday[0] and $today != $btoday[1]) or empty($birthdays)) { // Need to update! if (empty($birthdays)) { $DB_site->query("INSERT INTO template (templateid, templatesetid, title, template) VALUES (NULL, '-2', 'birthdays', '')"); } getbirthdays(); $birthdays = $DB_site->query_first("SELECT template FROM template WHERE title='birthdays' and templatesetid = -2"); $birthdays = $birthdays[template]; $btoday = explode('|||',$birthdays); } if ($today == $btoday[0]) { $birthdays = $btoday[2]; } elseif ($today == $btoday[1]) { $birthdays = $btoday[3]; } if ($birthdays) { eval("\$birthdaybits = \"".gettemplate("forumhome_birthdaybit")."\";"); } } //Forum info $forums=$DB_site->query('SELECT * FROM forum WHERE displayorder<>0 AND active=1 ORDER BY parentid,displayorder'); while ($forum=$DB_site->fetch_array($forums)) { $iforumcache["$forum[parentid]"]["$forum[displayorder]"]["$forum[forumid]"] = $forum; } $DB_site->free_result($forums); unset($forum); //Forum perms $forumperms=$DB_site->query("SELECT forumid,canview,canpostnew FROM forumpermission WHERE usergroupid='$bbuserinfo[usergroupid]'"); while ($forumperm=$DB_site->fetch_array($forumperms)) { $ipermcache["$forumperm[forumid]"] = $forumperm; } $DB_site->free_result($forumperms); unset($forumperm); $accesscache = array(); if ($bbuserinfo['userid']!=0 AND $enableaccess) { //Access table perms $accessperms=$DB_site->query("SELECT forumid,accessmask FROM access WHERE userid='$bbuserinfo[userid]'"); while ($accessperm=$DB_site->fetch_array($accessperms)) { $accesscache["$accessperm[forumid]"] = $accessperm; } $DB_site->free_result($accessperms); unset($accessperm); // usergroup defaults $usergroupdef['canview'] = $permissions['canview']; $usergroupdef['canpostnew'] = $permissions['canpostnew']; // array for accessmask=0 $noperms['canview'] = 0; $noperms['canpostnew'] = 0; } $imodcache = array(); $mod = array(); $forummoderators=$DB_site->query('SELECT user.userid,user.username,moderator.forumid FROM moderator LEFT JOIN user ON (moderator.userid=user.userid) ORDER BY user.username'); while ($moderator=$DB_site->fetch_array($forummoderators)) { $imodcache["$moderator[forumid]"][] = $moderator; $mod["$moderator[userid]"] = 1; } $DB_site->free_result($forummoderators); unset($moderator); $activeusers = ""; $loggedinusers = ""; if ($displayloggedin) { $datecut=time()-$cookietimeout; $loggedins=$DB_site->query_first("SELECT COUNT(*) AS sessions FROM session WHERE userid=0 AND lastactivity>$datecut"); $numberguest=$loggedins['sessions']; $numbervisible=0; $numberregistered=0; $loggedins=$DB_site->query("SELECT DISTINCT session.userid,username,invisible,usergroupid FROM session LEFT JOIN user ON (user.userid=session.userid) WHERE session.userid>0 AND session.lastactivity>$datecut ORDER BY invisible ASC, username ASC"); if ($loggedin=$DB_site->fetch_array($loggedins)) { $numberregistered++; if ($loggedin['invisible']==0 or $bbuserinfo['usergroupid']==6) { $numbervisible++; $userid = $loggedin['userid']; if ($loggedin['invisible'] == 1) { // Invisible User but show to Admin $invisibleuser = '*'; } else { $invisibleuser = ''; } if ($loggedin['usergroupid'] == 6 and $highlightadmin) { $username = "<b><i>$loggedin[username]</i></b>"; } else if (($mod["$userid"] or $loggedin['usergroupid'] == 5) and $highlightadmin) { $username = "<b>$loggedin[username]</b>"; } else { $username = $loggedin['username']; } eval("\$activeusers = \"".gettemplate('forumhome_loggedinuser')."\";"); } while ($loggedin=$DB_site->fetch_array($loggedins)) { $numberregistered++; $invisibleuser = ''; if ($loggedin['invisible']==1 and $bbuserinfo['usergroupid']!=6) { continue; } $numbervisible++; $userid=$loggedin['userid']; if ($loggedin['invisible'] == 1) { // Invisible User but show to Admin $invisibleuser = '*'; } if ($loggedin['usergroupid'] == 6 and $highlightadmin) { $username = "<b><i>$loggedin[username]</i></b>"; } else if (($mod["$userid"] or $loggedin['usergroupid'] == 5) and $highlightadmin) { $username = "<b>$loggedin[username]</b>"; } else { $username = $loggedin['username']; } eval("\$activeusers .= \", ".gettemplate('forumhome_loggedinuser')."\";"); } } $DB_site->free_result($loggedins); $totalonline=$numberregistered+$numberguest; $numberinvisible=$numberregistered-$numbervisible; $maxusers=explode(" ", gettemplate('maxloggedin',0,0)); if ((int)$maxusers[0] <= $totalonline) { $time = time(); $maxloggedin = "$totalonline " . $time; $DB_site->query("UPDATE template SET template='$maxloggedin' WHERE title='maxloggedin'"); $maxusers[0] = $totalonline; $maxusers[1] = $time; } $recordusers = $maxusers[0]; $recorddate = vbdate($dateformat,$maxusers[1]); $recordtime = vbdate($timeformat,$maxusers[1]); eval("\$loggedinusers = \"".gettemplate('forumhome_loggedinusers')."\";"); } // Start makeforumbit function makeforumbit($forumid,$depth=1,$permissions='') { global $DB_site,$bbuserinfo,$iforumcache,$ipermcache,$imodcache,$session,$accesscache,$usergroupdef,$noperms; global $showlocks,$hideprivateforums,$showforumdescription,$forumhomedepth,$dateformat,$timeformat,$enableaccess; if ( !isset($iforumcache["$forumid"]) ) { return; } $forumbits = ''; while ( list($key1,$val1)=each($iforumcache["$forumid"]) ) { while ( list($key2,$forum)=each($val1) ) { // Permissions if ( $enableaccess and is_array($accesscache["$forum[forumid]"]) ) { if ($accesscache["$forum[forumid]"]['accessmask']==1) { $forumperms = $usergroupdef; } else { $forumperms = $noperms; } } else if ( is_array($ipermcache["$forum[forumid]"]) ) { $forumperms = $ipermcache["$forum[forumid]"]; } else { $forumperms = $permissions; } $trueperm['canview'] = $forumperms['canview']; if (!$hideprivateforums) { $forumperms['canview']=1; } if (!$forumperms['canview']) { continue; } else { $forumshown=1; // do light bulb if ($bbuserinfo['lastvisitdate']=='Never') { $forum['onoff']='on'; } else { if (($fview = get_bbarraycookie('forumview', $forum['forumid'])) > $bbuserinfo['lastvisit']) { $userlastvisit=$fview; } else { $userlastvisit=$bbuserinfo['lastvisit']; } if ($userlastvisit<$forum['lastpost']) { $forum['onoff']='on'; } else { $forum['onoff']='off'; } } if ((!$forumperms['canpostnew'] and $showlocks) or $forum['allowposting']==0) { $forum['onoff'].='lock'; } // prepare template vars if (!$showforumdescription) { $forum['description']=''; } // dates if ($forum['lastpost']>0) { $maxchars='30'; // title lenght if($trueperm['canview']) { $forum['lastthread']=unhtmlspecialchars($forum['lastthread']); if (strlen($forum['lastthread']) > $maxchars) { $forum['lastthread'] = substr($forum['lastthread'], 0, $maxchars-2) . '...'; } } $forum['lastpostdate']=vbdate($dateformat,$forum['lastpost']); $forum['lastposttime']=vbdate($timeformat,$forum['lastpost']); eval("\$forum['lastpostinfo'] = \"".gettemplate('forumhome_lastpostby')."\";"); } else { $forum['lastpostinfo']='Never'; } $listexploded=explode(",", $forum['parentlist']); while ( list($mkey1,$mval1)=each($listexploded) ) { if ( !isset($imodcache["$mval1"]) ) { continue; } reset($imodcache["$mval1"]); while ( list($mkey2,$moderator)=each($imodcache["$mval1"]) ) { if ( !isset($forum['moderators']) ) { eval("\$forum['moderators'] = \"".gettemplate('forumhome_moderator')."\";"); } else { eval("\$forum['moderators'] .= \", ".gettemplate('forumhome_moderator')."\";"); } } } if ( !isset($forum['moderators']) ) { $forum['moderators'] = ' '; } if ($forum['cancontainthreads']==1) { $tempext = '_post'; } else { $tempext = '_nopost'; } eval("\$forumbits .= \"".gettemplate("forumhome_forumbit_level$depth$tempext")."\";"); if ($depth<$forumhomedepth) { $forumbits.=makeforumbit($forum['forumid'],$depth+1,$forumperms); } } // END if can view } // END while ( list($key2,$forum)=each($val1) ) { } // END while ( list($key1,$val1)=each($iforumcache["$forumid"]) ) { unset($iforumcache["$forumid"]); return $forumbits; } if (!isset($forumid) or $forumid==0 or $forumid=='') { $forumid=-1; } else { // need to get permissions for this specific forum $permissions=getpermissions(intval($forumid)); } $forumbits=makeforumbit(intval($forumid), 1, $permissions); /* vbStats [forumhome] #########################################*/ // Today post and threads [FireFly] $tltoday=time()-(86400); $getpoststoday=$DB_site->query_first("SELECT count(*) AS count FROM post WHERE dateline>='$tltoday'"); $poststoday=number_format(($getpoststoday[count]), 0, ',', '.'); $getthreadstoday=$DB_site->query_first("SELECT count(*) AS count FROM thread WHERE dateline>='$tltoday'"); $threadstoday=number_format(($getthreadstoday[count]), 0, ',', '.'); // Today Views $tltoday=time()-(86400); $todayboardviews = $DB_site->query_first("SELECT SUM(views) AS threadviews FROM thread WHERE dateline>='$tltoday'"); $todayviews = number_format(($todayboardviews[threadviews]), 0, ',', '.'); // ########## New Users Today $tltoday=time()-(86400); $getnewusertoday=$DB_site->query_first("SELECT count(*) AS count FROM user WHERE joindate>='$tltoday'"); $newusertoday=number_format(($getnewusertoday[count]), 0, ',', '.'); // PM Today $tltoday=time()-(86400); $todaypms = $DB_site->query_first("SELECT count(*) as pmcount FROM privatemessage WHERE dateline>='$tltoday'"); $todaypm = number_format(($todaypms[pmcount]), 0, ',', '.'); // 24 Hours $datecut3=time()-(86400); $toppost3=$DB_site->query("SELECT COUNT(post.userid) as posts, user.username, user.userid FROM post, user WHERE post.userid=user.userid AND post.dateline>=$datecut3 GROUP BY user.userid ORDER BY posts DESC LIMIT 1"); while ($user3=$DB_site->fetch_array($toppost3)) { $numbertopposts=number_format($user3[posts]); $topposter=($user3[username]); $topposterid=($user3[userid]); } eval("\$vbstats = \"".gettemplate('vbstats_forumhome')."\";"); // vbStats [forumhome] END $unregwelcomemessage=''; if ($bbuserinfo['userid']==0) { eval("\$unregwelcomemessage = \"".gettemplate('forumhome_unregmessage')."\";"); } eval("dooutput(\"".gettemplate('forumhome')."\");"); ?> Code:
<table align="left" border=0 cellpadding="0" cellspacing="0" valign="top"> <tr height="3"> <td></td> </tr> <tr align="left"> <td width="120"><smallfont><a href="memberlist.php?s=$session[sessionhash]">Iscritti</a>: <b>$numbermembers</b> </smallfont></td> <td><smallfont> Nuovi Iscritti: <b>$newusertoday</b> </smallfont></td> <td><smallfont> <a href="showgroups.php?s=$session[sessionhash]">Staff</a>: <b>$anum</b> </smallfont></td> <td><smallfont> Attivi: <b>$activemembers</b> </smallfont></td> <td><smallfont> Non Attivi: <b>$nonposters</b> </smallfont></td> <td colspan="2"><smallfont> % Attivi: <b>$activityrate<b><smallfont>%</b></smallfont></b> </smallfont></td></tr> <tr> <td><smallfont> Stat. totali: </smallfont></td> <td><smallfont> Discussioni: <b>$totalthreads</b> </smallfont></td> <td><smallfont> MP: <b>$totalpm</b> </smallfont></td> <td><smallfont> Post: <b>$totalposts</b> </smallfont></td> <td><smallfont> Visite: <b>$totalviews</b> </smallfont></td> <td><smallfont>Top Disc.: <b> <a href=showthread.php?threadid=$top3d1id>$top3d1title</a></b> </smallfont></td> <td><smallfont>($top3d1views Visite) </smallfont></td></tr> <tr> <td><smallfont> Stat. ultime 24 ore: </smallfont></td> <td><smallfont> Discussioni: <b>$threadstoday</b> </smallfont></td> <td><smallfont> <a href='private.php?s=$session[sessionhash]'>MP</a>: <b>$todaypm</b> </smallfont></td> <td><smallfont> <a href='search.php?action=getdaily'>Post</a>: <b>$poststoday</b> </smallfont></td> <td><smallfont> Visite: <b>$todayviews</b> </smallfont></td> <td><smallfont>Top Poster: <b><a href=member.php?action=getinfo&userid=$topposterid">$topposter</a></b> </smallfont></td> <td><smallfont>($numbertopposts Post) </smallfont></td></tr> </table> </td></tr> |
#1177
|
||||
|
||||
v2.3.3 here, and I am having the same problem as many others in this thread and in the 30+ posts I've read, no solution was offered.
Installation went easy. No errors. I get no parse errors or anything, but calling myforums.com/vbstats.php brings up... Quote:
How is this corrected? |
#1178
|
|||
|
|||
Great hack, but I think the design has WAY too many database hits and I definitely noticed a slowdown on my site, especially with a lot of users online. I made a couple small modifications that greatly reduce the database hits and improve performance.
1) Removed the "include("./vbs_counter.php");" from the phpinclude template. 2) Modified global.php: Find: if (!$servertoobusy) { require('./admin/sessions.php'); Add before: if (!isset($sessionhash)) include("./vbs_counter.php"); 3) Modified vbstats.php: Find: $vbs_today=time()-(86400); Add: $vbs_date = date("Y-m-j"); 4) Modified template vbstats_stats: Replaced text "Page Views" with "Sessions" Replaced text "Views" with "Sessions" (in last 24 hour section) That's it. What this essentially does is replace all page hit information with new session information. So the stats are only updated when a new session is created, not with every page hit. Although you lose the "Page Views" stat, everything else works fine, and the database only gets hit by vbs_counter.php when there's a new session rather than with every page hit. You would likely want to reset your counters after making this change. |
#1179
|
||||
|
||||
Quote:
HA, it even took care of the errors I was getting on my vbhome page. Cool! :up: |
#1180
|
||||
|
||||
I dont think Bane's going to release the update running on his site. aww never mind. thanx
|
#1181
|
||||
|
||||
@ bane, do you think you well port this hack to VB3?
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|