Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
general-topic
Can you remove the forum stats in the footer?
Avatar
Joshua McQueen
Denver, CO
Member
Free Members
sp_UserOfflineSmall Offline
May 27, 2012 - 12:59 am

Hey Everyone!

I absolutely love Simple:Press. I've got it setup just the way I want it, except one thing: 

Is there a way to remove the Forum Stats in the Footer? 

I see there are options like update interval, top posters, and number of new users. But I don't see a place to disable it completely. 

In an ideal world, I'd only want the Admin and Moderators to see that information.

If you can provide any assistance I'd really appreciate it. wink

Thanks! 

-Josh

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
May 27, 2012 - 1:11 am

yes, the vast majority of display elements is controlled by your sp theme...  so you can make any desired changes to the theme and have complete control over how your forum displays...

before changing your theme, we recommend making your own them rather than editing ours so you dont lose any changes should you update the theme... please see:  http://codex.simple-press.com/.....g-a-theme/ for simple instructions on creating your own theme...

once you have your own theme, you will want to edit the template file that displays the stats... in this case, is spFoot.php since it appears in the footer of each sp page...

In this template file, you will find an entire section devoted to displaying the stats... it starts with:

    # Start the 'stats' section
    # ----------------------------------------------------------------------
    sp_SectionStart('tagClass=spStatsSection', 'stats');

to completely remove the stats, simply remove the entire section and you wont have stats anymore...

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
May 27, 2012 - 1:12 am

if you only want admins and mods to see, make a check first...  just change it to:

    # Start the 'stats' section
    # ----------------------------------------------------------------------
    if ($spThisUser->admin || $spThisUser->moderator) {
        sp_SectionStart('tagClass=spStatsSection', 'stats');
            sp_ForumTimeZone('tagClass=spForumTimeZone', __sp('Forum Timezone: '));
            sp_UserTimeZone('tagClass=spUserTimeZone', __sp('Your Timezone: '));
    
            sp_InsertBreak();
    
            sp_ColumnStart('tagClass=spColumnSection spLeft spOnlineStats&width=40%&height=0');
                sp_OnlineStats('tagClass=spLeft', __sp('Most Users Ever Online: '), __sp('Currently Online: '), __sp('Currently Browsing this Page: '), __sp('Guest(s)'));
                if (function_exists('sp_OnlinePageLink')) sp_OnlinePageLink('', __sp('See All Online Activity'));
            sp_ColumnEnd();
    
            sp_ColumnStart('tagClass=spColumnSection spRight spTopPosterStats&width=15%&height=0');
                sp_TopPostersStats('tagClass=spRight', __sp('Top Posters: '));
            sp_ColumnEnd();
    
            sp_ColumnStart('tagClass=spColumnSection spRight spMembershipStats&width=20%&height=0');
                sp_MembershipStats('tagClass=spRight', __sp('Member Stats: '), __sp('Members: %COUNT%'), __sp('Guest Posters: %COUNT%'), __sp('Moderators: %COUNT%'), __sp('Admins: %COUNT%'));
            sp_ColumnEnd();
    
            sp_ColumnStart('tagClass=spColumnSection spRight spForumStats&width=17%&height=0');
                sp_ForumStats('tagClass=spRight', __sp('Forum Stats: '), __sp('Groups: '), __sp('Forums: '), __sp('Topics: '), __sp('Posts: '));
            sp_ColumnEnd();
    
            sp_InsertBreak();
    
            sp_NewMembers('tagClass=spLeft spNewMembers', __sp('Newest Members: '));
    
            sp_InsertBreak();
    
            sp_ModsList('tagClass=spLeft spModerators', __sp('Moderators: '));
    
            sp_InsertBreak();
    
            sp_AdminsList('tagClass=spLeft spAdministrators', __sp('Administrators: '));
        sp_SectionEnd('tagClass=spClear', 'stats');
    }
Avatar
Joshua McQueen
Denver, CO
Member
Free Members
sp_UserOfflineSmall Offline
May 27, 2012 - 1:20 am

Mr. Papa,

This was exactly what I was looking for!

Thank you SO MUCH for the information. I'll edit the theme and have this running in no time. 

Thanks again and have a good weekend kiss

-Josh

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
May 27, 2012 - 9:01 am

cool! thanks for the update.

Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 620
Members: 17365
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10128
Posts: 79626