Previous Thread
Next Thread
Print Thread
Rate Thread
Page 3 of 3 1 2 3
Joined: Jan 2000
Posts: 5,833
Likes: 20
UBBDev / UBBWiki Owner
Time Lord
UBBDev / UBBWiki Owner
Time Lord
Joined: Jan 2000
Posts: 5,833
Likes: 20
Lol, works perfectly. Be sure to clear your cache however... I hated having my total members up top using the fakemembertotal but the stats using the standard... Made it a pain to prune heh...


UBB.Dev - Putting Dev into UBB.threads
Company: VNC Web Services - UBB.threads Scripts and Scripting, Install and Upgrade Services, Site and Server Maintenance.
Forums: A Gardeners Forum, Scouters World, and UGN Security
UBB.Threads: My UBB Themes, My UBB Scripts
Sponsored Links
Joined: Jan 2003
Posts: 3,456
Likes: 2
Master Hacker
Master Hacker
Offline
Joined: Jan 2003
Posts: 3,456
Likes: 2
Also, for those who'd rather have " Page Views for March 2004:" than "Page Views 2004-03:"

In ubb_statistics.cgi
FIND:
Code
			my $bar = int(($Statistics{Hits}{$_} / $Statistics{Hits}{TotalViews}) * $vars_statistics{MaxBarLength});
ADD AFTER:
Code
			my $when = $_;
my @when = split(/-/, $when);
$when[1] = $when[1] + 0;
my $month = qq~month_~ . $when[1];
FIND:
Code
$vars_wordlets{statistics_monthly_hits} $_:
REPLACE WITH:
Code
$vars_wordlets{statistics_monthly_hits} for $vars_wordlets_date{$month} $when[0]:

Joined: May 2001
Posts: 1,042
Likes: 7
Moderator
Moderator
Offline
Joined: May 2001
Posts: 1,042
Likes: 7
Zip file updated with the fake member update. And the page views for month, year is now based on what user preference the date is on. So depending, you could get 04-2004 or April 2004. And there's other misc updates mainly with the spidering of urls.

The only file to update is ubb_statistics.cgi.

Joined: Jan 2003
Posts: 3,456
Likes: 2
Master Hacker
Master Hacker
Offline
Joined: Jan 2003
Posts: 3,456
Likes: 2
Brett, I was wondering if this would help make the hack less server intensive.

For the page views, how about making it so it uses a vars_statistics_views.cgi that saves the pageviews of older months, as my pageviews from 3 months ago won't change. This would make it so you would only open the one file for all those previous months, instead of at least one file per month. For really old sites that still use this (ie netwerkin), this could lead to a much better experience, wouldn't it?

That way, only the current month would need to have the pageviews be calculated, as it's always changing. Once the month changes, that is added to the vars file and you start the new month.


Sorry in advance if that's a really dumb idea

Joined: Apr 2004
Posts: 21
Junior Member
Junior Member
Offline
Joined: Apr 2004
Posts: 21
I'm having issues with this hack and my board is down!

The funny thing is that the statistics page is working fine but I am getting an error screen from my forum home.

Undefined subroutine &main::DisplayStats called at NonCGIPath/Templates/public_forum_summary.pl line 409.

http://www.firearmforums.com/cgi/ultimatebb.cgi

Please help!

Sponsored Links
Joined: May 2001
Posts: 1,042
Likes: 7
Moderator
Moderator
Offline
Joined: May 2001
Posts: 1,042
Likes: 7
Make sure you made and uploaded the changes in ubb_forum_summary.cgi.
Code
####################
# In ubb_forum_summary.cgi
####################
Find: #
##############
&set_page_elements;

##############
# Add Below: #
##############
&RequireCode("$vars_config{CGIPath}/ubb_statistics.cgi");

Joined: Apr 2004
Posts: 21
Junior Member
Junior Member
Offline
Joined: Apr 2004
Posts: 21
Yeah ... I'm dumarse and uploaded that file to my non-cgi directory instead of my cgi directory. Problem fixed. Thank you so much !

Joined: May 2001
Posts: 43
User
User
Offline
Joined: May 2001
Posts: 43
Hi, i've made a test installing this hack on my 6.6 boards and everything seems to be ok but for some issues: the statistics link in the upper line doesn't appear, just the space | |, and i cannot apply my ubb style to the statistics page, what could be wrong? Thanks!

Joined: Jan 2000
Posts: 5,833
Likes: 20
UBBDev / UBBWiki Owner
Time Lord
UBBDev / UBBWiki Owner
Time Lord
Joined: Jan 2000
Posts: 5,833
Likes: 20
Did you upload the updated vars_wordlets.cgi file?


UBB.Dev - Putting Dev into UBB.threads
Company: VNC Web Services - UBB.threads Scripts and Scripting, Install and Upgrade Services, Site and Server Maintenance.
Forums: A Gardeners Forum, Scouters World, and UGN Security
UBB.Threads: My UBB Themes, My UBB Scripts
Joined: May 2001
Posts: 43
User
User
Offline
Joined: May 2001
Posts: 43
Hi, yes, i updated it. I've tested it again and i get the same problems, in the Style Template Associations the statistics doesn't appear.
The docummentation says the Style Template Associations is located in: Primary Settings -> Style Templates -> Edit Style but in the 6.6 is located in Styles -> Style Associations. Is that wrong? or the docummentation is wrong?

Sponsored Links
Joined: Nov 2003
Posts: 156
Member
Member
Offline
Joined: Nov 2003
Posts: 156
Help???

Undefined subroutine &main::PageBottom called at CGIPath/ubb_forum_summary.cgi line 374.

Joined: Nov 2003
Posts: 156
Member
Member
Offline
Joined: Nov 2003
Posts: 156
I Found the problem to be in the public_forum_summary.pl

Joined: May 2001
Posts: 1,042
Likes: 7
Moderator
Moderator
Offline
Joined: May 2001
Posts: 1,042
Likes: 7
That's definitely not the stats hack. I would say rehack from a fresh file.

What is isle 6.7? Why would you need to change ubb_statistics.cgi?

Joined: May 2001
Posts: 1,042
Likes: 7
Moderator
Moderator
Offline
Joined: May 2001
Posts: 1,042
Likes: 7
6.7 zip updated with some new adjustments.

-Last topic now directly links to last post.
-Page views only tracks 6 months instead of loading all counter files that may extend further. smile

Joined: Jan 2000
Posts: 5,833
Likes: 20
UBBDev / UBBWiki Owner
Time Lord
UBBDev / UBBWiki Owner
Time Lord
Joined: Jan 2000
Posts: 5,833
Likes: 20
MMMK, how about publishing the changes so those of us running it can update our boards without having to rehack everything :x...


UBB.Dev - Putting Dev into UBB.threads
Company: VNC Web Services - UBB.threads Scripts and Scripting, Install and Upgrade Services, Site and Server Maintenance.
Forums: A Gardeners Forum, Scouters World, and UGN Security
UBB.Threads: My UBB Themes, My UBB Scripts
Joined: Jan 2003
Posts: 3,456
Likes: 2
Master Hacker
Master Hacker
Offline
Joined: Jan 2003
Posts: 3,456
Likes: 2
reupload ubb_statistics.cgi smile

Joined: Oct 2000
Posts: 2,667
Veteran
Veteran
Offline
Joined: Oct 2000
Posts: 2,667
I would to have, instead of averages, posts today, yesterday, posts this week, last week and posts this month, last month is it possible to gather such data?

thanks


Do you believe in love at first sight,
or should I walk by again?
Joined: Sep 2001
Posts: 672
Member
Member
Offline
Joined: Sep 2001
Posts: 672
How would one go about displaying the featured member at the top of public_forum_summary? I tried calling $DisplayFH like at the bottom, that didnt work, then I tried a print command right from ubb_statistics.cgi. No go...

Any ideas..

Joined: May 2001
Posts: 1,042
Likes: 7
Moderator
Moderator
Offline
Joined: May 2001
Posts: 1,042
Likes: 7
Charles: Not without diving deeper into the files, but that would require a ton more load, depending on the size of the forum. Because it would need to actually look at the date. The best i could think of is to create a maintaince routine to calculate all posts dates in a forum and append it to a main file with each row being week 1, week 2, so on, seperated by year. And then, increment by new posts. That would be the easiest on load.

Havoq:
Code
# before the print
&FeaturedMember;

# this variable holds featured
$Statistics{FeaturedMember}

Joined: Jan 2003
Posts: 3,456
Likes: 2
Master Hacker
Master Hacker
Offline
Joined: Jan 2003
Posts: 3,456
Likes: 2
Brett,

Code
		<tr bgcolor="$vars_style{AltColumnColor2}" class="darktable">
<td width="45%" valign="top">
<font size="$vars_style{TextSize}" face="$vars_style{FontFace}">
$vars_wordlets{statistics_average_posts}
</font>
</td>
<td valign="top">
<font size="$vars_style{TextSize}" face="$vars_style{FontFace}">
$Statistics{ForumStats}[2]
</font>
</td>
</tr>

<tr bgcolor="$vars_style{AltColumnColor1}" class="lighttable">
<td width="45%" valign="top">
<font size="$vars_style{TextSize}" face="$vars_style{FontFace}">
$vars_wordlets{statistics_average_topic}
</font>
</td>
<td valign="top">
<font size="$vars_style{TextSize}" face="$vars_style{FontFace}">
$Statistics{ForumStats}[1]
</font>
</td>
</tr>~;
should be

Code
		<tr bgcolor="$vars_style{AltColumnColor2}" class="darktable">
<td width="45%" valign="top">
<font size="$vars_style{TextSize}" face="$vars_style{FontFace}">
$vars_wordlets{statistics_average_posts}
</font>
</td>
<td valign="top">
<font size="$vars_style{TextSize}" face="$vars_style{FontFace}">
$Statistics{Average}[2]
</font>
</td>
</tr>

<tr bgcolor="$vars_style{AltColumnColor1}" class="lighttable">
<td width="45%" valign="top">
<font size="$vars_style{TextSize}" face="$vars_style{FontFace}">
$vars_wordlets{statistics_average_topic}
</font>
</td>
<td valign="top">
<font size="$vars_style{TextSize}" face="$vars_style{FontFace}">
$Statistics{Average}[1]
</font>
</td>
</tr>~;
I believe (changing ForumStats to Average)

Joined: Sep 2001
Posts: 672
Member
Member
Offline
Joined: Sep 2001
Posts: 672
Quote
Originally posted by Brett:

Havoq:
Code
# before the print
&FeaturedMember;
# this variable holds featured
$Statistics{FeaturedMember}

So how do you print it in forum summary? I've tried multiple things. qq~, print command, displayFH = qq~, etc etc

Joined: Sep 2001
Posts: 672
Member
Member
Offline
Joined: Sep 2001
Posts: 672
N/M, figured it out:

open ubb_forum_summary.cgi

Find:
Code
$ThisHTML = $Header;
Add Above:
Code
&FeaturedMember;

Joined: Sep 2001
Posts: 672
Member
Member
Offline
Joined: Sep 2001
Posts: 672
How many hours can the featured member stay? Whats the max? Because last night, I set it for a specific member at 12:01am. However, it switched members this morning I think around 12pm. Which means thats only 12 hours. I set it to update every 24. Hmmmm...

Joined: Sep 2001
Posts: 672
Member
Member
Offline
Joined: Sep 2001
Posts: 672
My featured member isn't even working correctly. I keep setting the user #, and then 1 hour for the random rotation. After an hour, it keeps setting itself to member #1, which is me, and it doesnt change. Very strange....

Joined: Aug 2004
Posts: 20
Junior Member
Junior Member
Offline
Joined: Aug 2004
Posts: 20
usually i have problems when i try to modify mine, but this one worked fine! Only problem i found was somehow it doesnt space from my last forum it just kinda goes right into it and looks crammed.. any help on that?

http://www.neverendingrejection.com/cgi-bin/ultimatebb.cgi

Joined: Dec 2001
Posts: 20
Junior Member
Junior Member
Offline
Joined: Dec 2001
Posts: 20
Help!

Just installed the stats package on a 6.7 board.

Code
An error has occurred: 

Unmatched ( in regex; marked by <-- HERE in m/(2005|2004)-( <-- HERE [01]([0-3]|[10-12])(-dynamic|-cache|).cgi$/ at CGIPath/ubb_statistics.cgi line 684.

Joined: Jan 2003
Posts: 3,456
Likes: 2
Master Hacker
Master Hacker
Offline
Joined: Jan 2003
Posts: 3,456
Likes: 2
try editing the following line in ubb_statistics.cgi

Code
$g_month = $raffle[0] . ']([' . $raffle[1] . "|[$back" . '-12]';
to become

Code
$g_month = $raffle[0] . ']([' . $raffle[1] . "|[$back" . '-12])';

Joined: Dec 2001
Posts: 20
Junior Member
Junior Member
Offline
Joined: Dec 2001
Posts: 20
Praise to Ian!

That did it.

Joined: Dec 2001
Posts: 20
Junior Member
Junior Member
Offline
Joined: Dec 2001
Posts: 20
Does "Statistics" show page views for a given forum? For instance i want to see which forums are the most popular.

Joined: Jan 2003
Posts: 3,456
Likes: 2
Master Hacker
Master Hacker
Offline
Joined: Jan 2003
Posts: 3,456
Likes: 2
no it does not. refer to my reply to you in the other topic.

Joined: Dec 2001
Posts: 20
Junior Member
Junior Member
Offline
Joined: Dec 2001
Posts: 20
Maybe the "hits hack" is what i should try.

Joined: Jan 2003
Posts: 3,456
Likes: 2
Master Hacker
Master Hacker
Offline
Joined: Jan 2003
Posts: 3,456
Likes: 2
that would give you totals, but it wouldn't tell you how many in a certain month

Joined: May 2001
Posts: 1,042
Likes: 7
Moderator
Moderator
Offline
Joined: May 2001
Posts: 1,042
Likes: 7
Updated the zip file per Ian's fix. Thankya much! smile

Joined: Sep 2005
Posts: 136
Journeyman
Journeyman
Offline
Joined: Sep 2005
Posts: 136
An error has occurred:

/(2006|2005)-([01]([0-2]|[9-12]))(-dynamic|-cache|).cgi$/: invalid [] range "9-1" in regexp at CGIPath/ubb_statistics.cgi line 684.

Please inform the board administration of this error so that they may fix the problem. Thank you!

Joined: May 2001
Posts: 1,042
Likes: 7
Moderator
Moderator
Offline
Joined: May 2001
Posts: 1,042
Likes: 7
AshtarRose / Any who are receiving this error,

I have updated the zip file, with ubb_statistics.cgi having the only changes to fix this bug once and for all.

https://www.ubbdev.com/ubb/upload/00006378/Statistics6.7.zip

Let me know if something comes up.

Page 3 of 3 1 2 3

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
Posts: 70
Joined: January 2007
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)