Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Mod Requests => Aiheen aloitti: dursunali - tammikuu 31, 2012, 07:11:26 IP

Otsikko: members statistics on board main page
Kirjoitti: dursunali - tammikuu 31, 2012, 07:11:26 IP
I want to see members statistics on  board main page especially 'Total Time Spent Online'
Otsikko: Re: members statistics on board main page
Kirjoitti: dursunali - tammikuu 31, 2012, 07:41:07 IP
is there any person can help to me !
Otsikko: Re: members statistics on board main page
Kirjoitti: Illori - tammikuu 31, 2012, 08:05:16 IP
not if you are that impatient to even wait more then 30 minutes for a reply. remember we are all volunteers and especially when wanting a mod it can take several days for someone to find the request and decide if they want to work on it.

also i have removed your other topic on this, dont make multiple topics on the same thing.
Otsikko: Re: members statistics on board main page
Kirjoitti: dursunali - tammikuu 31, 2012, 08:12:41 IP
maybe this is importanf for you , I have send twice because another person may be deal to me ! and also after you are warn to me then send a reply for me .
Otsikko: Re: members statistics on board main page
Kirjoitti: dursunali - helmikuu 01, 2012, 07:51:43 AP
Have anyone to help me !
Otsikko: Re: members statistics on board main page
Kirjoitti: hcfwesker - helmikuu 02, 2012, 10:12:25 IP
I'm confused kind of.  Do you just want the current member viewing the page, their stat showing for themself?  Or do you want the whole stat page showing of all members ?

For Total Time Logged in on every page.  This was made on the SMF Default theme, may be different on other themes.


index.template.php

Find
<li><a href="', $scripturl, '?action=unreadreplies">', $txt['show_unread_replies'], '</a></li>';

add After
// Show the total time logged in?
if (!empty($context['user']['total_time_logged_in']))
{
echo '<li>
', $txt['totalTimeLogged1'];

// If days is just zero, don't bother to show it.
if ($context['user']['total_time_logged_in']['days'] > 0)
echo $context['user']['total_time_logged_in']['days'] . $txt['totalTimeLogged2'];

// Same with hours - only show it if it's above zero.
if ($context['user']['total_time_logged_in']['hours'] > 0)
echo $context['user']['total_time_logged_in']['hours'] . $txt['totalTimeLogged3'];

// But, let's always show minutes - Time wasted here: 0 minutes ;).
echo $context['user']['total_time_logged_in']['minutes'], $txt['totalTimeLogged4'], '</li><br />';
}
Otsikko: Re: members statistics on board main page
Kirjoitti: dursunali - helmikuu 03, 2012, 12:10:16 IP
I want to this function on the user profile ,when someone acccess to form he can see follow the statistics ,

Default Statistics
Show unread posts since last visit.
Show new replies to your posts
03 Şubat, 2012, 19:00:20
-----------------------------------------
Show unread posts since last visit.
Show new replies to your posts
03 Şubat, 2012, 19:00:20
'Total Time Spent Online'




Otsikko: Re: members statistics on board main page
Kirjoitti: hcfwesker - helmikuu 03, 2012, 12:43:39 IP
The edit I provided will make it appear above today's date.  You can move the code under the code for the date in the file if you wish.
Otsikko: Re: members statistics on board main page
Kirjoitti: dursunali - helmikuu 03, 2012, 12:54:28 IP
you are exactly more than great :) thanx in advice and co-operation .
Otsikko: Re: members statistics on board main page
Kirjoitti: hcfwesker - helmikuu 03, 2012, 01:01:53 IP
You're welcome.  glad it worked as you wanted. :)
Otsikko: Re: members statistics on board main page
Kirjoitti: dursunali - helmikuu 03, 2012, 01:36:40 IP
definetly  it was worked exactly  like I wanna .