php forum
php mysql forum
php mysql smarty
 
Topic Options
#313509 - 03/12/07 03:35 PM total pageviews per month on summary page
Wendy Anderson Offline
Junior Member

Registered: 06/27/05
Posts: 17

   total pageviews per month on summary page to Del.icio.us Add to del.icio.us
  Digg total pageviews per month on summary page Digg it
How could I get the total monthly pageviews statistic to appear on my forum summary page? It appears on the control panel page, per below. Could that segment be moved just below my copywrite info at the page bottom of the forum summary (or next to the total members statistic.)

Still working with 6.7.2 but have upgraded though not installed 6.7.3. Much, much thanks!

from cp2_home.pl:

my $pageview_string;
my $total_hits;

if($monthly_hits > 0) { # old hit counter format
if(($cache_hits > 0) && ($dynamic_hits > 0)) {
$total_hits = $cache_hits + $dynamic_hits;
my $perc_dynamic = sprintf("%2.3f", $dynamic_hits / $total_hits);
my $perc_cache = 100 * sprintf("%.4f", $cache_hits / $total_hits);
$pageview_string = <<THEEND;
$vars_wordlets_cp2{home_pageviews} ($GotTime{mon}/$GotTime{JSYear}): <strong>$total_hits</strong>
<br />$vars_wordlets_cp2{home_pageviews_cached}: <strong>$perc_cache</strong>%<br />
THEEND
} else {
$total_hits = $cache_hits + $dynamic_hits + $monthly_hits;
$pageview_string = <<THEEND;
$vars_wordlets_cp2{home_pageviews} ($GotTime{mon}/$GotTime{JSYear}): <strong>$total_hits</strong><br />
THEEND
} # end if
} else { # new hit counter format
if(($cache_hits > 0) && ($dynamic_hits > 0)) {
$total_hits = $cache_hits + $dynamic_hits;
my $perc_dynamic = sprintf("%2.3f", $dynamic_hits / $total_hits);
my $perc_cache = 100 * sprintf("%.4f", $cache_hits / $total_hits);
$pageview_string = <<THEEND;
$vars_wordlets_cp2{home_pageviews} ($GotTime{mon}/$GotTime{JSYear}): <strong>$total_hits</strong>
<br />$vars_wordlets_cp2{home_pageviews_cached}: <strong>$perc_cache</strong>%<br />
THEEND
} else {
$total_hits = $cache_hits + $dynamic_hits + $monthly_hits;
$pageview_string = <<THEEND;
$vars_wordlets_cp2{home_pageviews} ($GotTime{mon}/$GotTime{JSYear}): <strong>$total_hits</strong><br />
THEEND
} # end if
} # end if

Top
#313519 - 03/13/07 09:39 AM Re: total pageviews per month on summary page [Re: Wendy Anderson]
AllenAyres Administrator Offline
I type Like navaho

Registered: 03/10/00
Posts: 25429
Loc: Texas
You'd need to require that wordlet file too ($vars_wordlets_cp2), but it looks like it should work.

You could also try requiring the template fiel itself and just putting this where you want it:

$vars_wordlets_cp2{home_pageviews} ($GotTime{mon}/$GotTime{JSYear}): <strong>$total_hits</strong><br />

Not sure if it would work, haven't touched classic except for imports for a while now - will always remain my fave forum, just don't use it anymore smirk
_________________________
- Allen wavey
- What Drives You?

Top


Moderator:  Gizmo 
Who's Online
0 Registered (), 19 Guests and 5 Spiders online.
Key: Admin, Global Mod, Mod
Shout Box

Latest Posts
Blogs, love em or hate em?
by AllenAyres
Yesterday at 02:05 PM
What do you use to edit the files
by Ian_W
10/05/08 03:33 PM
BeyondCompare v3.00
by Ian_W
10/05/08 03:32 PM
Glossy Black Theme with Image Reflection
by Gizmo
10/05/08 02:17 PM
ShareThis
by Gizmo
09/28/08 05:06 AM
[7.3] Viewing MySQL logfiles made easier
by AllenAyres
09/27/08 09:57 PM
Looking for a simple upload script
by Murphdog
09/26/08 08:45 PM
New Mods
[7.3] Viewing MySQL logfiles made easier
by blaaskaak
09/24/08 05:39 PM
[7.3] Language file checker
by blaaskaak
09/09/08 12:56 AM
[7.3.1] add search to showmembers page
by blaaskaak
09/07/08 04:50 AM
Multiple Identity Detector
by
12/30/06 06:39 PM
Newest Members
pisa666, ghengis317, NitroX, Dogan, EliYah-
13345 Registered Users
Top Posters Last 30 Days
blaaskaak 12
AllenAyres 10
FREAK1 7
Mike L_dup1 4
Chris Bale 4
Ian_W 4
tackaberry 4

 

 

 
fusionbb message board php hacks