Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: Nibogo on November 06, 2005, 01:42:31 AM

Title: Users Online Today Mod
Post by: Nibogo on November 06, 2005, 01:42:31 AM
Link to the mod (https://custom.simplemachines.org/index.php?mod=217)

(https://www.smfpacks.com/imagenes/nuevo_logo_mod.png) (http://www.smfpacks.com)
Users Online Today by SMFPacks.com (http://www.smfpacks.com)
Creator:

Originally created by Carceri (http://www.simplemachines.org/community/index.php?action=profile;u=30615)

Developer:

www.smfpacks.com (http://www.smfpacks.com)

Important Info:

This Mod is developer by SMFPacks.com - The #1 Website for the Customziation of your SMF. SMFPacks.com Provides Other Great Packages:

- Reason for Editing Mod.
- Yet Another Global Announcements Mod.
- SMF Social Groups.
- SMF Links Directory.
- SMF Downloads Directory.
- SMF Dynamic Directory.
- Advanced Topic Prefix Mod.
- Advanced Invitations System.
- Move Topic Notification.
- PM to New Members.
- Permissions Info.
- Next Post Level.
- Karma Buttons.
- SMF Multi Quote.
- Attachments in Topics.
- and much more visit us on SMFPacks.com

Description:

Adds a list of all users that were online on the current day to the 'Info Center'. This is a simple mod that does the job and not a whole lot more. I like to keep it simple.

Features:
- By hovering the cursor over the username, it will display when the user was last logged in
- The time period that the user list shows can be the current day, last 24 hours or last week
- The list can be sorted in various ways
- Viewing of the list can be restricted

It modifies files in the default theme, so if you are using any other theme you need to make changes to your theme files. I offer no support for this.

Upgrading:

Just uninstall whatever version you've installed and install the latest one.

Languages:

- Croatian.
- Danish.
- Dutch.
- English.
- Finnish.
- German.
- Hungarian.
- Persian.
- Portuguese.
- Russian.
- Serbian.
- Spanish.
- Turkish.
Title: Re: Users Online Today Mod
Post by: Teknomancer on November 06, 2005, 09:46:40 AM
This doesn't seem to work for me. Just installed it on SMF 1.1. RC1... nothing has changed in the Info Center.

Is there any setting that needs to be enabled?
Title: Re: Users Online Today Mod
Post by: xenovanis on November 06, 2005, 11:13:54 AM
If you are using a custom theme, you probably need to make some changes to your themefiles.

How to make mods work with themes? (http://www.simplemachines.org/community/index.php?topic=34526.0)
Title: Re: Users Online Today Mod
Post by: snork13 on November 06, 2005, 05:54:53 PM
works great in 1.1rc1, thanks for sharing


-snork
Title: Re: Users Online Today Mod
Post by: xenovanis on November 06, 2005, 06:24:01 PM
Actually, I got this errormessage:

8: Undefined index: num_buddies
File: .../forum/Sources/BoardIndex.php
Regel: 298

This is how I fixed it. BoardIndex.php

Code (find) Select

        $context['users_online_today'] = array();
$context['list_users_online_today'] = array();


Code (add after) Select

$context['num_buddies'] = array();


Probably a dirty fix  :P
Title: Re: Users Online Today Mod
Post by: Carceri on November 06, 2005, 07:33:16 PM
You are right that this is a bug, and the correct fix is not adding the line that uses $context['num_buddies'] which is:

$context['num_buddies']++;

Your fix works as well, but should be

$context['num_buddies'] = 0;

:)

Thanks for reporting it. It has been fixed in the latest version.
Title: Re: Users Online Today Mod
Post by: thetzfreak on November 06, 2005, 09:55:34 PM
Do I have to do the custom editing thing for my theme even after you updated it now?
Title: Re: Users Online Today Mod
Post by: Carceri on November 07, 2005, 01:34:47 AM
Quote from: thetzfreak on November 06, 2005, 09:55:34 PM
Do I have to do the custom editing thing for my theme even after you updated it now?
If you have a file called 'BoardIndex.template.php' in your theme dir, then you need to edit it manually. This mod only edits it for the default theme.
Title: Re: Users Online Today Mod
Post by: jerm on November 07, 2005, 04:01:11 PM
lol, just realized it
with the other online users mod it wasn't a huge deal, but with this one it can be a bigger deal i guess
but for those users who like to remain hidden, they hide in the "users online", but they arn't hidden on the "users online today" section.. and now you can just hover over their nickname to see when they were last active.
think theres a fix for this?
Title: Re: Users Online Today Mod
Post by: Carceri on November 07, 2005, 04:23:03 PM
It's easy to make a fix. The question is what the right fix is :)

Just a question: What happens if you go to a profile of a user who does not want to be shown on the today list. Can you still see when that user was last logged in? If yes, then I think this mod does not reveal any more information that what could already be found elsewhere and I think it should be left as it is.

If that information is not shown in the users profile, then we should probably do something. The easy fix is to simply remove the user from the list and add some additional text like:

13 users online today (3 hidden):
<<13 usernames of non-hidden users>>

Suggestions?
Title: Re: Users Online Today Mod
Post by: xenovanis on November 07, 2005, 04:26:28 PM
I think it's okay to show them in the list, but not in an italic font. Now, you can see all hidden users easily.
Title: Re: Users Online Today Mod
Post by: Carceri on November 07, 2005, 04:32:08 PM
Are the hidden users shown with an italic font? I have never noticed that, but perhaps it's because I'm an administrator on the board?
Title: Re: Users Online Today Mod
Post by: xenovanis on November 07, 2005, 04:38:36 PM
Yes, in the online list their names are shown in italic font to administrators. Normal users can't see they are online.

In your mod, their names also appear in a italic font, but they are now also visible like this to other users. It's like drawing extra attention to them IMO. I found this in BoardIndex.php

$context['list_users_online_today'][$row['lastLogin'] . $row['memberName']] = empty($row['showOnline']) ? ' <i>' . $link . ' </i>' : $link;
and removed the <i> tags to normalize the font.
Title: Re: Users Online Today Mod
Post by: Carceri on November 07, 2005, 04:41:30 PM
Yes, but it is the same code that apparently hides them from regular users in the users online list. I will have to investigate why the same code hides the users from the online list, but not the online today list.

Then I will make the correct fix.
Title: Re: Users Online Today Mod
Post by: xenovanis on November 07, 2005, 04:42:06 PM
No, it doesn't. I tested it. This works correct  ;)
Title: Re: Users Online Today Mod
Post by: Carceri on November 07, 2005, 04:47:11 PM
Sorry, what works correct?
Title: Re: Users Online Today Mod
Post by: xenovanis on November 07, 2005, 04:49:41 PM
Removing the <i> tags keeps the users hidden (or italic to admins) in the current online list, and shows hidden users in a normal font in the online today list.
Title: Re: Users Online Today Mod
Post by: Carceri on November 07, 2005, 04:55:04 PM
I don't quite understand this. Are you saying that this mod modifies the behaviour of the current online list?
Title: Re: Users Online Today Mod
Post by: xenovanis on November 07, 2005, 05:01:11 PM
No, it doesn't affect the current online list. Sorry for the confusion.  :-\

But it does show to ordinary members whether a member has choosen to be hidden, by displaying it's username in an italic font in the "users online today" list. I think you should get rid of that, because it's drawing extra attention to this profile. People start wondering why this name is italicized and their own name isn't.
Title: Re: Users Online Today Mod
Post by: Carceri on November 07, 2005, 05:04:30 PM
My confusion comes from your answer to my comment where I said that I needed to investigate this, because from looking at the code my first impression is that everything works as it should, and I understood that you said that I should't look at the code because everything works ok. Now I understand again :)

While removing the <i> might work, I don't think this is the correct fix. Something else is wrong here, and I am hesistant to make a fix before I really understand what I am fixing :)
Title: Re: Users Online Today Mod
Post by: 1MileCrash on November 07, 2005, 05:06:07 PM
since the problem is that their names are italicised, then removeing <i></i> will work..it's like the only fix.
Title: Re: Users Online Today Mod
Post by: xenovanis on November 07, 2005, 05:07:47 PM
Quote from: Carceri on November 07, 2005, 05:04:30 PM
My confusion comes from your answer to my comment where I said that I needed to investigate this, because from looking at the code my first impression is that everything works as it should, and I understood that you said that I should't look at the code because everything works ok. Now I understand again :)

While removing the <i> might work, I don't think this is the correct fix. Something else is wrong here, and I am hesistant to make a fix before I really understand what I am fixing :)

Okay, glad that was cleared  :)

I agree it's probably not the best way to fix it, it's more like a quick fix for lazy people  ;)
Title: Re: Users Online Today Mod
Post by: Carceri on November 07, 2005, 05:13:42 PM
Quote from: Tippmaster on November 07, 2005, 05:06:07 PM
since the problem is that their names are italicised, then removeing <i></i> will work..it's like the only fix.
Not really, because the usernames should be in italic to the administrators and hidden from everyone else. Also the same code hides the users from non-administrators in the current online list, but shows them to everyone in the online today list.
Title: Re: Users Online Today Mod
Post by: Carceri on November 07, 2005, 05:49:20 PM
I think I have a fix, could somebody please try it and see if it works?

What should you expect:

As an administrator:
Hidden users are shown in italic
Hovering the mouse over their name shows when they were last online

As a regular user:
Hidden users are show as non-italic like all other users
Hovering the mouse over their name will not show when they were last online

Edit: Link removed. The latest version can be found in the first post in this thread.
Title: Re: Users Online Today Mod
Post by: xenovanis on November 07, 2005, 06:01:29 PM
Seems to work like a charm  ;)
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 07, 2005, 07:19:30 PM
I have a question. All the last on times are the normal forum time. COuld you make it so it adjusts to each person's local time?
Title: Re: Users Online Today Mod
Post by: 1948Pal on November 07, 2005, 10:39:11 PM
This is a nice mod, but isn't this exactly the same mod made by FaSan, I think, who's mod was removed from SMF for some reason?
Title: Re: Users Online Today Mod
Post by: jerm on November 07, 2005, 11:33:46 PM
wow, wasn't expecting it to be fixed so fast lol.. well done. i like it like this :)
Title: Re: Users Online Today Mod
Post by: Carceri on November 08, 2005, 01:21:56 AM
Quote from: Libo on November 07, 2005, 07:19:30 PM
I have a question. All the last on times are the normal forum time. COuld you make it so it adjusts to each person's local time?
It's on my TODO list :)
Title: Re: Users Online Today Mod
Post by: Carceri on November 08, 2005, 01:23:10 AM
Quote from: 1948Pal on November 07, 2005, 10:39:11 PM
This is a nice mod, but isn't this exactly the same mod made by FaSan, I think, who's mod was removed from SMF for some reason?
I wouldn't know. I just converted my forum from phpBB and was missing this feature, and since I couldn't find a mod like this I made one myself.
Title: Re: Users Online Today Mod
Post by: Carceri on November 08, 2005, 07:56:04 AM
New version 1.2.0 RC1 can be downloaded here:

http://www.bytopia.dk/Users_Online_Today_1.2.0_RC1.zip (http://www.bytopia.dk/Users_Online_Today_1.2.0_RC1.zip)

This version should handle timezones properly depending on the user's time offset. All times are displayed as local times, and also "users online today" means today in the timezone the user is in, not the forum time. Also last login times are displayed according to the user's preferences (12/24 hrs. am/pm).

Since I can only do limited testing (I don't have a forum with users in different timezones) I leave it here for you to test. Please report any problems.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 08, 2005, 11:38:38 AM
There is a problem. You see. It doesn't use the forum time. even the original version doesn't use the forum time...


It is 3 hours behind my forum time..

You can test by going to profile and changing your default time to something and see if it works.
Title: Re: Users Online Today Mod
Post by: Hachi on November 08, 2005, 03:27:58 PM
Could someone please help  :'(, i have just installed this mod but its not working, i keep getting the following error:

2: in_array(): Wrong datatype for second argument
File: /home/fearncou/public_html/forum/Sources/BoardIndex.php
Line: 271

I am using a template but i have put it back to the default template and had no joy, any help would be great..

Thanks

Hachi
Title: Re: Users Online Today Mod
Post by: Carceri on November 08, 2005, 04:03:50 PM
Quote from: Libo on November 08, 2005, 11:38:38 AM
There is a problem. You see. It doesn't use the forum time. even the original version doesn't use the forum time...

It is 3 hours behind my forum time..

You can test by going to profile and changing your default time to something and see if it works.
The original didn't that's true, but with the new version, when I change my timeoffset from 0 to, say -1, then the online times are all shown as being one hour earlier than forum time. So to answer your last line, yes I did it and it does work :)

But seriously, any information you can provide will help me identify the problem. It's hard to correct when it works for me. If you hover the mouse over a user and it displays his last online time and you then click on the same user and checks the last online field there. What is the difference between those two?
Title: Re: Users Online Today Mod
Post by: Carceri on November 08, 2005, 04:09:16 PM
Quote from: Hachi on November 08, 2005, 03:27:58 PM
2: in_array(): Wrong datatype for second argument
File: /home/fearncou/public_html/forum/Sources/BoardIndex.php
Line: 271
I'm sorry I can't help you there, since your BoardIndex.php is apparently not the same as a patched one from the original version of SMF 1.1 RC1. Line 271 in BoardIndex.php should be a comment added by my mod, and nothing related to in_array(). Are you sure you are patching an unmodified version of BoardIndex.php?
Title: Re: Users Online Today Mod
Post by: jerm on November 08, 2005, 07:15:23 PM
Quote from: 1948Pal on November 07, 2005, 10:39:11 PM
This is a nice mod, but isn't this exactly the same mod made by FaSan, I think, who's mod was removed from SMF for some reason?
fasan took his mod off the list
Title: Re: Users Online Today Mod
Post by: Menni on November 09, 2005, 05:10:59 AM
Can someone pleae specify for me how and what should I modify to make this mod work in some other theme?
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 09, 2005, 07:23:48 AM
Just follow the instructions inside the package. It is the .xml file. Then edit Boardindex.template.php with its edits...
Title: Re: Users Online Today Mod
Post by: galgoz on November 09, 2005, 06:14:54 PM
After installing the mod I get this error

2: in_array(): Wrong datatype for second argument
File: /home/content/M/R/e/MReimann/html/smf/Sources/BoardIndex.php
Line: 271

Line 271 and the following lines read as follows.

$is_buddy = in_array($row['ID_MEMBER'], $user_info['buddies']);
      if ($is_buddy)
      {
         $link = '<b>' . $link . '</b>';
      }

Any ideas?
Title: Re: Users Online Today Mod
Post by: Carceri on November 10, 2005, 01:29:10 AM
Quote from: galgoz on November 09, 2005, 06:14:54 PM
$is_buddy = in_array($row['ID_MEMBER'], $user_info['buddies']);
Could you sent me your entire BoardIndex.php file? Line 271 in my patched file is not this line, so I need to check what the differences between our files are in order to see what is wrong.

Are you using SMF 1.1 RC1 ?
Title: Re: Users Online Today Mod
Post by: Carceri on November 10, 2005, 05:43:11 AM
To all of you that experience this problem:

2: in_array(): Wrong datatype for second argument
File: /home/content/M/R/e/MReimann/html/smf/Sources/BoardIndex.php
Line: 271

This is because you are running SMF 1.0.5. I have only made this mod for SMF 1.1 RC1. Apparently $user_info['buddies'] is not defined in SMF 1.0.5. A quick fix for this problem is to delete the following from BoardIndex after applying the patch:


$is_buddy = in_array($row['ID_MEMBER'], $user_info['buddies']);
if ($is_buddy)
{
$link = '<b>' . $link . '</b>';
}


and probably also the line


'is_buddy' => $is_buddy,


Please note that this mod does not support SMF 1.0.5 and there is no guarantee that it will work for that version, even with the fix mentioned here.
Title: Re: Users Online Today Mod
Post by: Rebelbelle on November 10, 2005, 09:13:44 PM
Quote from: 1948Pal on November 07, 2005, 10:39:11 PM
This is a nice mod, but isn't this exactly the same mod made by FaSan, I think, who's mod was removed from SMF for some reason?

I have that mod on another one of my boards.  What I really liked about that one, is it also added the users online in a day to the statistics center.  Does the current mod do that?
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 11, 2005, 07:19:13 AM
Nope. But you can get that mod from fasan's site.
Title: Re: Users Online Today Mod
Post by: jerm on November 11, 2005, 03:40:16 PM
think you could make it possible for this to appear on the [stats] page as "most online users today" ?
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 11, 2005, 04:00:49 PM
Probably. but it would require more coding.
Title: Re: Users Online Today Mod
Post by: Carceri on November 11, 2005, 07:27:12 PM
Quote from: electrohome88 on November 11, 2005, 03:40:16 PM
think you could make it possible for this to appear on the [stats] page as "most online users today" ?
Sure, the question is how to do it. All the other stats that relate to 'today' are using as today, the forum time and does not take into account the other users' timezones, so I guess that this "most online users today" should do the same, otherwise it will be confusing, right?

But the list of users online today on the front page, are shown as today taking into account the timezone of the user viewing the frontpage.

In order to make it consistent, I would suggest the following:

- Add a "most online users today" to the [stats] page showing the number of online users today, where today is seem from the forum time.

- Make the list on the frontpage display the users online today according to the forum time, not the user's time (the popup with the last time the user was seen will still be shown in the user's time)

Comments, ideas, etc.?
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 12, 2005, 12:56:58 PM
I think that would be great!
Title: Re: Users Online Today Mod
Post by: jerm on November 12, 2005, 10:54:35 PM
i would keep it the same way it does the other stats.. where it goes by the forum time
Title: Re: Users Online Today Mod
Post by: Carceri on November 13, 2005, 08:30:12 AM
Okay, the latest version (1.3.0 RC1) should now act according to the description above. Please test it and report any problems.
Title: Re: Users Online Today Mod
Post by: Nightstalker on November 14, 2005, 06:08:21 AM
Are there any plans to make this mod work with SMF 1.05.

Cheers.
Title: Re: Users Online Today Mod
Post by: Carceri on November 14, 2005, 07:02:14 AM
When everything is working as it should for 1.1 RC1, I might make a version compatible with 1.0.5.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 14, 2005, 08:15:10 PM
1.3 doesn't seem to work.. like, the stats don't show up(no tables?) and the time is still wacky on mouse over...
Title: Re: Users Online Today Mod
Post by: jonc on November 15, 2005, 01:30:25 AM
I installed the mod both v1.20 and v1.30 both version only worked when my local time is 13:00 to 0:00.  From 0:00 to 12:59 the mod doesn't work.

My local time is GMT+8, and my SMF time offset is set to 13hrs
Title: Re: Users Online Today Mod
Post by: Carceri on November 15, 2005, 01:58:09 AM
Libo: Have you copied BoardIndex.template.php and Stats.template.php from the default theme to your custom theme or modified your themefiles accordingly?

jonc: Thans for the info (finally someone provided a concrete example where it doesn't work). Still I would like to know what doesn't work. What does the time show and what should it show. If you click the username, what does "Last Active:" say?
Title: Re: Users Online Today Mod
Post by: jonc on November 15, 2005, 02:27:30 AM
When you roll the mouseover it shows the "last active" time.  Everythings OK except nothing shows up (no name, no time) between 0:00 to 12:59 GMT+8 visit http://www.mykapitbahay.com
Title: Re: Users Online Today Mod
Post by: Carceri on November 15, 2005, 03:03:25 AM
Thanks for the info. I can see the problem now and will fix it when I have the time, probably in a day or two.
Title: Re: Users Online Today Mod
Post by: beemer on November 15, 2005, 07:24:38 AM
Well if it helps I havnt found any problems running gmt 0 offset

Great mod thanx

http://www.bmw7resource.co.uk/forum/index.php
Title: Re: Users Online Today Mod
Post by: Carceri on November 15, 2005, 07:38:36 AM
The problem is related to the SMF time offset. If the forum is set to the same timezone as the server running the forum, everything should be fine. Problems only occur if you change the "Overall time offset" to something different from 0.

The fix is rather simple. When calculating the time for midnight, I need to convert midnight seen from the forum time, into midnight as seen from the timezone of the server since the lastLogin times in the database are represented in the servers timezone.

A quick untested fix is to replace the following two lines in BoardIndex.php

$frag = explode('-', strftime('%Y-%m-%d', forum_time(false)));
$midnight = mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]);


with

$frag = explode('-', strftime('%Y-%m-%d', time()));
$midnight = forum_time(false, mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]));


Please report back if this works or not.

Another needed fix is to have information such as today or yesterday in the popup time, since with certain configurations of timezones you can end up having users online today seen from the forum time, be yesterday seen from your time.

Edit: 1.3.0 RC2 includes all these fixes
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 15, 2005, 09:05:26 PM
Quote from: Carceri on November 15, 2005, 01:58:09 AM
Libo: Have you copied BoardIndex.template.php and Stats.template.php from the default theme to your custom theme or modified your themefiles accordingly?

jonc: Thans for the info (finally someone provided a concrete example where it doesn't work). Still I would like to know what doesn't work. What does the time show and what should it show. If you click the username, what does "Last Active:" say?

Yes, i'm using default with the normal code...

This still doesn't work. It is 3 hours behind my fourm time(which is my server time...)

It doesn't add the time difference between server and forum time... That's what's going wrong...

Stat thing doesn't work. Maybe no mysql tables? In the stats.php you should query the tables that have the info..
Title: Re: Users Online Today Mod
Post by: jonc on November 15, 2005, 10:17:49 PM
Cool!  Everything's fine now!

I uninstalled 1.30 RC1 and install 1.30 RC2!

Thanks for the mod!  :D
Title: Re: Users Online Today Mod
Post by: jonc on November 16, 2005, 12:14:13 AM
Sorry bout my last post, it's working this morning but since 13:00 local time (GMT+8) it doesn't work.  Nothing shows up!
Title: Re: Users Online Today Mod
Post by: Carceri on November 16, 2005, 02:14:02 AM
Quote from: jonc on November 16, 2005, 12:14:13 AM
Sorry bout my last post, it's working this morning but since 13:00 local time (GMT+8) it doesn't work.  Nothing shows up!
Okay, so we try again. I only have a few minutes now, so this is just an idea, but it can't work any worse than it already does :)

The change can be found in 1.3.0 RC3.

This seems to work here, but the problem is probably that I always test at a specific time of day.
Title: Re: Users Online Today Mod
Post by: Juggler on November 16, 2005, 05:21:41 AM
Have to agree it's a nice mod but I really would like the "Stats Centre" Users Online Today column back. It's more of a cosmetic thing and not vital to the mod but it would be nice to have it in there if at all possible!
Title: Re: Users Online Today Mod
Post by: Carceri on November 16, 2005, 11:20:37 AM
Quote from: Juggler on November 16, 2005, 05:21:41 AM
Have to agree it's a nice mod but I really would like the "Stats Centre" Users Online Today column back. It's more of a cosmetic thing and not vital to the mod but it would be nice to have it in there if at all possible!
It is back in the latest RC version as "Total Users Online Today"
Title: Re: Users Online Today Mod
Post by: [ZW] Leviathan on November 16, 2005, 12:56:50 PM
That is under the General Statistics part of the Stats page, right?

What Juggler is probably refering to (I think) is the Total Users Online column in the Forum History part at the bottom of the Stats page. That used to have an additional column with that information, I would like to see that back there as well :)
Title: Re: Users Online Today Mod
Post by: Juggler on November 16, 2005, 02:53:56 PM
That's correct. It's the forum history bit as mentioned.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 16, 2005, 04:46:44 PM
fix the forum time difference between server time. in next version plz
Title: Re: Users Online Today Mod
Post by: Carceri on November 16, 2005, 06:10:33 PM
Quote from: Libo on November 16, 2005, 04:46:44 PM
fix the forum time difference between server time. in next version plz
Then help me fix it by giving me useful information :) For example, does the suggested fix above work? It works for me and I have done some limited testing by changing the forum timezone and it seems to work. That said, I made this for myself and later thought that others might be able to use it which is the reason I added it here. Unfortunately I don't have much time to do a thorough test, sorry.

Regarding the other question, I will probably add it later, but right now I prefer to fix the timezone problem. I don't know what "used to have" means. I have never seen that feature before. It is probably related to another users online today mod, but I have never seen that one, so...
Title: Re: Users Online Today Mod
Post by: jonc on November 16, 2005, 09:35:16 PM
I've installed RC3...as of now everything's fine...my local time now is 10:33 (GMT+8)...i'll wait till 13:00 and see if everything's still fine :)

Thanks again to Carceri for sharing and for his effort  :)
Title: Re: Users Online Today Mod
Post by: jonc on November 17, 2005, 01:03:17 AM
It's 14:00 (GMT+8) now! mod's still working fine! looks like Carceri has fixed the timezone problem!  :D
Title: Re: Users Online Today Mod
Post by: Carceri on November 17, 2005, 02:41:00 AM
If it still works in 24 hours or so, I'll promote RC3 to final :)

Thanks for helping out with the testing.

The forum history bit will be for a later version.
Title: Re: Users Online Today Mod
Post by: [ZW] Leviathan on November 17, 2005, 08:34:56 AM
Regarding the Users Online Today in the History part...

Quote from: Carceri on November 16, 2005, 06:10:33 PM
I don't know what "used to have" means. I have never seen that feature before. It is probably related to another users online today mod, but I have never seen that one, so...

Hmmm... interesting  ::)

I'll have a look if I can find that one, because I'm sure I had it on my forum not so long ago :)
Title: Re: Users Online Today Mod
Post by: Juggler on November 17, 2005, 10:26:53 AM
I didn't realise that this was a new mod on the same lines as the Fasan one at first. What I thought was an updated version of a mod I used to have has turned out to be a different one albeit it does the same thing. I prefer the way this one works with the time popping up on mouseover it would just be nice to have the Historical part that was on the other similar modification.
Title: Re: Users Online Today Mod
Post by: Carceri on November 17, 2005, 02:04:46 PM
I had a similar mod for my phpBB forum, but when I upgraded to SMF, I couldn't find a similar mod, so I made it myself. That is the reason for this mod. When I searched I found references to the Fasan mod, but never a download link.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 17, 2005, 06:00:40 PM
sorry, didn't realize there was rc3. My mistake...

Still doesn't work... LIke, i changed my forum time and everything. It didn't work...
Title: Re: Users Online Today Mod
Post by: jonc on November 17, 2005, 08:54:30 PM
It's almost 24hrs since I installed RC3, everything's running smoothly!  I can say that timezone has been fixed! Mod has been working for the last 23h24m. On mouseover, It popups the "last online" time of the user w/ correct time offsetting.

Keep it up Carceri!  Thanks for the mod!
Title: Re: Users Online Today Mod
Post by: Carceri on November 18, 2005, 02:12:34 AM
Quote from: Libo on November 17, 2005, 06:00:40 PMStill doesn't work... LIke, i changed my forum time and everything. It didn't work...
You need to be more specific. I find it hard to believe that the time on the popup is different from the "Last Active" on a users profile, since the mod uses the exact same code to display the time. If that is not the problem, then what is. Has you changed the forum time offset, user time offset, does this happen to all users, what if you are not logged in, what does the forum time says compared to the time on the server itself?, etc...
Title: Re: Users Online Today Mod
Post by: Carceri on November 18, 2005, 03:46:47 AM
Quote from: jonc on November 17, 2005, 08:54:30 PM
It's almost 24hrs since I installed RC3, everything's running smoothly!  I can say that timezone has been fixed! Mod has been working for the last 23h24m. On mouseover, It popups the "last online" time of the user w/ correct time offsetting.
I watched your forum as midnight passed (your time) and it started a new day after that as it should. I have also experimented more with timezones with a negative offset here, and it seems to work fine as well.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 18, 2005, 07:29:37 AM
Quote from: Carceri on November 18, 2005, 02:12:34 AM
Quote from: Libo on November 17, 2005, 06:00:40 PMStill doesn't work... LIke, i changed my forum time and everything. It didn't work...
You need to be more specific. I find it hard to believe that the time on the popup is different from the "Last Active" on a users profile, since the mod uses the exact same code to display the time. If that is not the problem, then what is. Has you changed the forum time offset, user time offset, does this happen to all users, what if you are not logged in, what does the forum time says compared to the time on the server itself?, etc...

Yes, it is exactly 3 hours different. Which is difference from forum time to server time.

When, I'm not logged in, it is still 3 hours behind...

The forum time offset is 3 hours...  Your thing is perfect except it is 3 hours behind. You can go to my site to see....
Title: Re: Users Online Today Mod
Post by: Carceri on November 18, 2005, 07:58:10 AM
I have checked and double checked the source code, and it does take into account the forum time offset in the latest version, but I noticed one thing that I found strange. When going to a user's profile on your forum the time is displayed as 'am' or 'pm' but the popup text over the username does not say 'am' or 'pm'. The latest mod should read these settings from the forum and display the time in the same format.

This, and the fact that on the other boards I have seen (including my own) this mod applies the forum time offset correctly, leads me to believe that you are not running the latest version of this mod (1.3.0 RC3). Could you please check your BoardIndex.php file and verify that is corresponds to the changes that this mod applies? Also that you are patching the files that are actually served by the webserver.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 18, 2005, 11:49:05 AM
What latest? It is still 1.3.0 rc3...

I am pretty sure the boardindex.php file is modified correctly according to 1.3.0 rc3 because when i uninstall, it works properly...

QuoteAlso that you are patching the files that are actually served by the webserver.

What does that mean?
Title: Re: Users Online Today Mod
Post by: Carceri on November 18, 2005, 12:02:57 PM
Quote from: Libo on November 18, 2005, 11:49:05 AM
QuoteAlso that you are patching the files that are actually served by the webserver.
What does that mean?
If you have multiple forums, then that you are patching the right one :) Yes, a longshot, but the behaviour you are experiencing are not consistent with 1.3.0 RC3.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on November 18, 2005, 02:57:50 PM
very long shot. I only have one forum...

Ah, i see. it was because I had multiple edits. I must have had one from 1.0 and frogot to uninstall.

It works perfectly now...

Only question when is stats center gonna be working?
Title: Re: Users Online Today Mod
Post by: beemer on November 18, 2005, 03:57:43 PM
Quote from: Libo on November 18, 2005, 02:57:50 PM
very long shot. I only have one forum...

Ah, i see. it was because I had multiple edits. I must have had one from 1.0 and frogot to uninstall.

It works perfectly now...

Only question when is stats center gonna be working?


It is ? Isnt it?

GREAT Mod Thanx alot Carceri
Title: Re: Users Online Today Mod
Post by: Carceri on November 18, 2005, 08:39:12 PM
Quote from: Libo on November 18, 2005, 02:57:50 PM
Only question when is stats center gonna be working?
One short answer: I don't know :) Right now things are working and the added functionality to the stats center is a feature for a future release. I have looked at it briefly and it doesn't seem to be that hard to implement, but it will require changes to the database. When I have some time to do it, I will do it, but I can't promise a date.

The most important thing for me (regarding this mod) was to get 1.3.0 final ready which is done now.

Thanks all for helping me with the timezone problems. I'm glad that so many people can actually use this mod that I originally made just for myself :)
Title: Re: Users Online Today Mod
Post by: Juggler on November 19, 2005, 01:53:55 AM
OK,

Just logged into my forum (6:51am) and it's not picking me up as being logged in today. So as far as the "Users Online Today" Section is concerned no one has been online as it's it's showing 0 people online. So I made sure it wasn't a theme problem and went into the default theme and it still shows 0 people online.

Thoughts?
Title: Re: Users Online Today Mod
Post by: Carceri on November 19, 2005, 05:27:49 AM
Must be some timezone problem that haven't been fixed. You know what information I need to look at it :)

Of course, first make sure that you are running 1.3.0
Title: Re: Users Online Today Mod
Post by: Juggler on November 19, 2005, 05:33:47 AM
Well I installed the latest version the other day but when checking the files I found that it still had the old offset code. So I changed the code as mentioned in the thread but still have the same problem. I'm at work at the moment so I can't access the files just set so I'll dig into it later.

Which files do you need again?
Title: Re: Users Online Today Mod
Post by: Carceri on November 19, 2005, 05:52:04 AM
I would like to know the server time, forum time, whether or not the error occurs when you are logged in or as guest. If you can provide your BoardIndex.php then I can see that there are no old parts of some previous modification that are messing things up.
Title: Re: Users Online Today Mod
Post by: Juggler on November 19, 2005, 06:34:15 AM
No problem, I'll dig it out later. Looking at the admin side of things I'm at plus 5 on the overall offset to bring it to UK time. So I guess that would make it 1.51am on the server?

I'll mail/PM you the boardIndex file when I can get at it.
Title: Re: Users Online Today Mod
Post by: Juggler on November 19, 2005, 06:54:57 AM
OK, managed to access the file via my cpanel so here's all the Online Today stuff from it :-

Quote// Load the users online today.
   $nowdate = @getdate(forum_time(false));
   $midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);

   $s = strpos($user_info['time_format'], '%S') === false ? '' : ':%S';
   if (strpos($user_info['time_format'], '%H') === false && strpos($user_info['time_format'], '%T') === false)
      $time_fmt = '%I:%M' . $s . ' %p';
   else
      $time_fmt = '%H:%M' . $s;

   $result = db_query("
      SELECT
         mem.ID_MEMBER, mem.lastLogin, mem.realName, mem.memberName, mem.showOnline,
         mg.onlineColor, mg.ID_GROUP, mg.groupName
      FROM {$db_prefix}members AS mem
         LEFT JOIN {$db_prefix}membergroups AS mg ON (mg.ID_GROUP = IF(mem.ID_GROUP = 0, mem.ID_POST_GROUP, mem.ID_GROUP)) WHERE mem.lastLogin >= $midnight", __FILE__, __LINE__);

   $context['users_online_today'] = array();
   $context['list_users_online_today'] = array();

   while ($row = mysql_fetch_assoc($result))
   {
      $userday = strftime('%d', forum_time(true));
      $loginday = strftime('%d', forum_time(true, $row['lastLogin']));
      $yesterday = $userday == $loginday ? '' : $txt['uot_yesterday'];
   
      $lastLogin = $yesterday . strftime($time_fmt, forum_time(true, $row['lastLogin']));
      $title = (allowedTo('moderate_forum') || !empty($row['showOnline'])) ? ' title="' . $lastLogin . '"' : '';

      // Some basic color coding...
      if (!empty($row['onlineColor']))
         $link = ' $row['ID_MEMBER'],
         'username' => $row['memberName'],
         'name' => $row['realName'],
         'group' => $row['ID_GROUP'],
         'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
         'link' => $link,
         'is_buddy' => $is_buddy,
         'hidden' => empty($row['showOnline']),
      );

      $context['list_users_online_today'][$row['lastLogin'] . $row['memberName']] = (empty($row['showOnline']) && allowedTo('moderate_forum')) ? '' . $link . '' : $link;
   }
   mysql_free_result($result);

   krsort($context['users_online_today']);
   krsort($context['list_users_online_today']);

   $context['num_users_online_today'] = count($context['users_online_today']);
         
   // Load the users online today.
   $frag = explode('-', strftime('%Y-%m-%d', time()));
$midnight = forum_time(false, mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]));

   $s = strpos($user_info['time_format'], '%S') === false ? '' : ':%S';
   if (strpos($user_info['time_format'], '%H') === false && strpos($user_info['time_format'], '%T') === false)
      $time_fmt = '%I:%M' . $s . ' %p';
   else
      $time_fmt = '%H:%M' . $s;

   $result = db_query("
      SELECT
         mem.ID_MEMBER, mem.lastLogin, mem.realName, mem.memberName, mem.showOnline,
         mg.onlineColor, mg.ID_GROUP, mg.groupName
      FROM {$db_prefix}members AS mem
         LEFT JOIN {$db_prefix}membergroups AS mg ON (mg.ID_GROUP = IF(mem.ID_GROUP = 0, mem.ID_POST_GROUP, mem.ID_GROUP)) WHERE mem.lastLogin >= $midnight", __FILE__, __LINE__);

   $context['users_online_today'] = array();
   $context['list_users_online_today'] = array();

   while ($row = mysql_fetch_assoc($result))
   {
      $lastLogin = strftime($time_fmt, forum_time(true, $row['lastLogin']));
      $title = (allowedTo('moderate_forum') || !empty($row['showOnline'])) ? ' title="' . $lastLogin . '"' : '';

      // Some basic color coding...
      if (!empty($row['onlineColor']))
         $link = ' $row['ID_MEMBER'],
         'username' => $row['memberName'],
         'name' => $row['realName'],
         'group' => $row['ID_GROUP'],
         'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
         'link' => $link,
         'is_buddy' => $is_buddy,
         'hidden' => empty($row['showOnline']),
      );

      $context['list_users_online_today'][$row['lastLogin'] . $row['memberName']] = (empty($row['showOnline']) && allowedTo('moderate_forum')) ? '' . $link . '' : $link;
   }
   mysql_free_result($result);

   krsort($context['users_online_today']);
   krsort($context['list_users_online_today']);

   $context['num_users_online_today'] = count($context['users_online_today']);
         
   // Load the users online right now.
   $result = db_query("
      SELECT
         lo.ID_MEMBER, lo.logTime, mem.realName, mem.memberName, mem.showOnline,
         mg.onlineColor, mg.ID_GROUP, mg.groupName
      FROM {$db_prefix}log_online AS lo
         LEFT JOIN {$db_prefix}members AS mem ON (mem.ID_MEMBER = lo.ID_MEMBER)
         LEFT JOIN {$db_prefix}membergroups AS mg ON (mg.ID_GROUP = IF(mem.ID_GROUP = 0, mem.ID_POST_GROUP, mem.ID_GROUP))", __FILE__, __LINE__);

   $context['users_online'] = array();
   $context['list_users_online'] = array();
   $context['online_groups'] = array();
   $context['num_guests'] = 0;
   $context['num_buddies'] = 0;
   $context['num_users_hidden'] = 0;

   $context['show_buddies'] = !empty($user_info['buddies']);

   while ($row = mysql_fetch_assoc($result))
   {
      if (empty($row['realName']))
      {
         $context['num_guests']++;
         continue;
      }
      elseif (empty($row['showOnline']) && !allowedTo('moderate_forum'))
      {
         $context['num_users_hidden']++;
         continue;
      }

      // Some basic color coding...
      if (!empty($row['onlineColor']))
         $link = '' . $row['realName'] . '';
      else
         $link = '' . $row['realName'] . '';

      $is_buddy = in_array($row['ID_MEMBER'], $user_info['buddies']);
      if ($is_buddy)
      {
         $context['num_buddies']++;
         $link = '' . $link . '';
      }

      $context['users_online'][$row['logTime'] . $row['memberName']] = array(
         'id' => $row['ID_MEMBER'],
         'username' => $row['memberName'],
         'name' => $row['realName'],
         'group' => $row['ID_GROUP'],
         'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
         'link' => $link,
         'is_buddy' => $is_buddy,
         'hidden' => empty($row['showOnline']),
      );

      $context['list_users_online'][$row['logTime'] . $row['memberName']] = empty($row['showOnline']) ? '' . $link . '' : $link;

      if (!isset($context['online_groups'][$row['ID_GROUP']]))
         $context['online_groups'][$row['ID_GROUP']] = array(
            'id' => $row['ID_GROUP'],
            'name' => $row['groupName'],
            'color' => $row['onlineColor']
         );
   }
   mysql_free_result($result);

   krsort($context['users_online']);
   krsort($context['list_users_online']);
   ksort($context['online_groups']);

   $context['num_users_online'] = count($context['users_online']) + $context['num_users_hidden'];
Title: Re: Users Online Today Mod
Post by: Jorg40 on November 19, 2005, 11:01:48 AM
I have a small problem

"2.     Execute Modification     ./Themes/default/BoardIndex.template.php     Failure"

What is the cause to this? I'm using a skin, can that be the problem?
Title: Re: Users Online Today Mod
Post by: Carceri on November 19, 2005, 12:05:03 PM
Quote from: Juggler on November 19, 2005, 06:54:57 AM
OK, managed to access the file via my cpanel so here's all the Online Today stuff from it :-

You have both the old and the new version installed. The line

// Load the users online today.

indicates the start of the mod, but is present two places in the file. First comes the new version and after that the old version, which overwrites the settings from the new version.
Title: Re: Users Online Today Mod
Post by: Carceri on November 19, 2005, 01:01:59 PM
Quote from: Jorg40 on November 19, 2005, 11:01:48 AM
I have a small problem

"2.     Execute Modification     ./Themes/default/BoardIndex.template.php     Failure"

What is the cause to this? I'm using a skin, can that be the problem?
Apparently something has changed BoardIndex.template.php and my mod is only tested agains the original file. You can probably still apply the mod manually.
Title: Re: Users Online Today Mod
Post by: Jorg40 on November 19, 2005, 01:59:15 PM
How to install it manually?

Here is the total list of errors in 1.3.0

1. Execute Modification ./Sources/BoardIndex.php Success  
2. Execute Modification ./Sources/Stats.php Failure
3. Execute Modification ./Themes/default/BoardIndex.template.php Failure
4. Execute Modification ./Themes/default/Stats.template.php Failure
5. Execute Modification ./Themes/default/languages/Modifications.english.php Success
6. Execute Modification ./Themes/default/languages/Stats.english.php Failure

I use SMF 1.0.5
Title: Re: Users Online Today Mod
Post by: Carceri on November 19, 2005, 02:03:29 PM
Quote from: Jorg40 on November 19, 2005, 01:59:15 PM
How to install it manually?
http://www.simplemachines.org/community/index.php?topic=34526.0

Quote from: Jorg40 on November 19, 2005, 01:59:15 PM
I use SMF 1.0.5
This mod does not support SMF 1.0.5
Title: Re: Users Online Today Mod
Post by: Jorg40 on November 19, 2005, 03:57:52 PM
What version does it support then?
Title: Re: Users Online Today Mod
Post by: Carceri on November 19, 2005, 04:13:49 PM
Quote from: Jorg40 on November 19, 2005, 03:57:52 PM
What version does it support then?
It is written on the download page for the mod... 1.1 RC1
Title: Re: Users Online Today Mod
Post by: Jorg40 on November 19, 2005, 04:51:03 PM
Sorry, didnt read close enough... so now I have one last question:

How does I change the path of the install to anther skin?
Or do I have to install it manually then?
Title: Re: Users Online Today Mod
Post by: Carceri on November 19, 2005, 06:07:29 PM
Quote from: Jorg40 on November 19, 2005, 04:51:03 PM
How does I change the path of the install to anther skin?
Or do I have to install it manually then?
You can change the file section of the mod, but I would suggest to install it manually as it might not even work on some themes.
Title: Re: Users Online Today Mod
Post by: Jorg40 on November 19, 2005, 08:07:43 PM
I use the BlackDay theme, and its similar to Default
Title: Re: Users Online Today Mod
Post by: Dannii on November 21, 2005, 10:45:02 PM
It would be nice if you could eventually make this mod show the history as well, and maybe even convert (or use the same format logs) as FaSan's mod. Do you know the format he used? Would a database dump be useful at all? I think it's just a simple integer number for each day.
Title: Re: Users Online Today Mod
Post by: Carceri on November 22, 2005, 02:43:49 AM
There are no current plans for adding the history bit, although I might do it later when I have more time. Right now I have a lot of other work to do. If someone can tell me the format of the database fasan used, I can probably do it in the same way so it will most likely be compatible with databases already modified to use fasans mod. A dump of the database structure would be fine.
Title: Re: Users Online Today Mod
Post by: Juggler on November 22, 2005, 04:08:40 AM
Quote from: Carceri on November 19, 2005, 12:05:03 PM
Quote from: Juggler on November 19, 2005, 06:54:57 AM
OK, managed to access the file via my cpanel so here's all the Online Today stuff from it :-

You have both the old and the new version installed.


How the heck did I manage that????? All sorted and working fine as intended, thanks for the assist.
Title: Re: Users Online Today Mod
Post by: mforum on November 22, 2005, 04:30:40 AM
Any chance have a version of this mod for SMF 1.0.5 with classic theme ?  ::)
Title: Re: Users Online Today Mod
Post by: Dannii on November 22, 2005, 07:10:39 AM
FaSan's mod simply does this query (it checks first but this is all that matters):
db_query("ALTER TABLE {$db_prefix}log_activity
ADD `allOn` smallint(5) unsigned NOT NULL default '0'", __FILE__, __LINE__);

It then alters that every time someone is added to the list. If you could get that working the history page would then be identical, and noone would have to change themes :D
Title: Re: Users Online Today Mod
Post by: Carceri on November 22, 2005, 08:02:43 AM
That should be simple to add. When I get a few minutes I will probably do it :)
Title: Re: Users Online Today Mod
Post by: beemer on November 22, 2005, 08:39:06 AM
Unlikely  :( though fasans mod is still about (on his site ?)
Title: Re: Users Online Today Mod
Post by: gerrymore on November 22, 2005, 04:14:56 PM
Shame there is no simplified manual install instrucions on how to add this to other themes for non-coders like me. Yes I know the info is there, but other mods have had simplified versions in a text file on how to do it all.
Title: Re: Users Online Today Mod
Post by: FaSan on November 28, 2005, 03:12:19 AM
Great Mod ! and Great idea   :P :P :P
Title: Re: Users Online Today Mod
Post by: Carceri on November 28, 2005, 05:02:33 AM
Quote from: FaSan on November 28, 2005, 03:12:19 AM
Great Mod ! and Great idea   :P :P :P
Thanks :P I had no idea that you had done a similar mod. I got the idea from http://www.phpbb.com/phpBB/viewtopic.php?t=253650 and looked here but found nothing of that sort.
Title: Re: Users Online Today Mod
Post by: FaSan on November 28, 2005, 03:30:57 PM
Quote from: Carceri on November 28, 2005, 05:02:33 AM
Quote from: FaSan on November 28, 2005, 03:12:19 AM
Great Mod ! and Great idea   :P :P :P
Thanks :P I had no idea that you had done a similar mod. I got the idea from http://www.phpbb.com/phpBB/viewtopic.php?t=253650 and looked here but found nothing of that sort.


No problem for me. My post is a joke. I've delete my mods from that site.


FaSan
Title: Re: Users Online Today Mod
Post by: Carceri on November 28, 2005, 04:39:02 PM
I know it's a joke, but actually I am a little curious. Why did you delete your mod? It could have saved me the trouble of doing this myself  :P
Title: Re: Users Online Today Mod
Post by: mforum on November 29, 2005, 04:09:08 AM
I have installed Fasan`s mod changing 1-2 lines to work with classic theme and my forum lanquage at SMF 1.0.5
Works just perfect .. !!! Pity this mod is vanished from here  ::)
Title: Re: Users Online Today Mod
Post by: FaSan on November 29, 2005, 04:49:09 AM
Quote from: Carceri on November 28, 2005, 04:39:02 PM
I know it's a joke, but actually I am a little curious. Why did you delete your mod? It could have saved me the trouble of doing this myself  :P


Because the Staff of this Site does not interest to the quality, but only to the amount.

Don't exist the good rules, and not exist the given word.



FaSan
Title: Re: Users Online Today Mod
Post by: diegolyanky on December 04, 2005, 03:27:27 PM
Good mod, but:

I installed, and I modified files of my theme helios_multi manually and doesn't work ...

I uninstalled old User Online Today mod ...

Here is the code of my BoardIndex.template.php

<?php
// Version: 1.0.3; BoardIndex

function template_main()
{
        global $context, $settings, $options, $txt, $scripturl, $modSettings , $sourcedir;


        $topbox='<table width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="height: 16px; width: 22px;"><img src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-topleft.gif" style="height: 16px; width: 22px; border: 0px; padding: 0px; margin: 0px;" alt="gfx" /></td><td style="height: 16px; background-image: url('.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-topmid.gif); "></td><td style="height: 16px; width: 27px;"><img alt="gfx" src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-topright.gif" style="height: 16px; width: 27px; border: 0px; padding: 0px; margin: 0px;" /></td></tr><tr><td style="width: 22px; background-image: url('.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-midleft.gif); "></td><td valign="top">';
        $botbox='</td><td style="width: 27px; background-image: url('.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-midright.gif); "></td></tr><tr><td style="height: 14px; width: 22px;"><img alt="gfx" src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-botleft.gif" style="height: 14px; width: 22px; border: 0px; padding: 0px; margin: 0px;" /></td><td style="height: 14px; background-image: url('.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-botmid.gif); "></td><td style="height: 14px; width: 27px;"><img alt="gfx" src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-botright.gif" style="height: 14px; width: 27px; border: 0px; padding: 0px; margin: 0px;" /></td></tr></table>';

        $leftbox='<table width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="height: 54px; width: 72px;"><img alt="gfx" src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-board-lefttop.gif" style="height: 54px; width: 72px; border: 0px; padding: 0px; margin: 0px;" /></td><td nowrap="nowrap" style="text-align: center; height: 54px; background-image: url('.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-board-midtop.gif); ">';
        $rightbox='</td><td style="height: 54px; width: 79px;"><img alt="gfx" src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-board-topright.gif" style="height: 54px; width: 79px; border: 0px; padding: 0px; margin: 0px;" /></td></tr></table>';


        $leftboxbot='<table width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="padding-left: 5px; height: 78px; width: 72px;"><img alt="gfx" src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-board-botleft.gif" style="height: 78px; width: 72px; border: 0px; padding: 0px; margin: 0px;" /></td><td valign="top" nowrap="nowrap" style="text-align: center; height: 78px; background-image: url('.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-board-botmid.gif); ">';
        $rightboxbot='</td><td style="height: 78px; width: 79px;"><img alt="gfx" src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-board-botright.gif" style="height: 78px; width: 79px; border: 0px; padding: 0px; margin: 0px;" /></td></tr></table>';

        $leftboxbot2='<table width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="padding-left: 4px; height: 36px; width: 72px;"><img alt="gfx" src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-topleft-40.gif" style="height: 36px; width: 72px; border: 0px; padding: 0px; margin: 0px;" /></td><td valign="top" nowrap="nowrap" style="text-align: center; height: 36px; background-image: url('.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-topmid-41.gif); ">';
        $rightboxbot2='</td><td style="padding-right: 0px; height: 36px; width: 79px;"><img alt="gfx" src="'.$settings['images_url'].'/pod/'.$options['theme_color'].'/pod-info-topright-42.gif" style="height: 36px; width: 79px; border: 0px; padding: 0px; margin: 0px;" /></td></tr></table>';


        // Show some statistics next to the link tree if SP1 info is off.
        echo $leftbox.'
<table width="100%" cellpadding="0" cellspacing="0">
        <tr>
                <td style="text-align: left; padding-left: 0px;" valign="bottom">', theme_linktree(), '</td>
        </tr>
</table>'.$rightbox;

        // Show the news fader?  (assuming there are things to show...)
        if ($settings['show_newsfader'] && !empty($context['fader_news_lines']))
        {
                echo $topbox;
                echo '
<div style="padding: 0px; margin-bottom: 2px;">
        <table border="0" width="100%" cellspacing="1" cellpadding="4">
                <tr>
                        <td align="left" style="font-weight: bold;">&nbsp;&nbsp;', $txt[102], '</td>
                </tr>
                <tr>
                        <td valign="middle" align="center" height="60">';

                // Prepare all the javascript settings.
                echo '
                                <div id="smfFadeScroller" style="width: 90%; padding: 2px; color: #ffffff;"><b>', $context['news_lines'][0], '</b></div>
                                <script language="JavaScript1.2" type="text/javascript"><!--
                                        // The fading delay (in ms.)
                                        var smfFadeDelay = ', empty($settings['newsfader_time']) ? 5000 : $settings['newsfader_time'], ';
                                        // Fade from... what text color?  To which background color?
                                        var smfFadeFrom = {"r": 255, "g": 255, "b": 255}, smfFadeTo = {"r": 0, "g": 0, "b": 0};
                                        // Surround each item with... anything special?
                                        var smfFadeBefore = "<b>", smfFadeAfter = "</b>";

                                        // List all the lines of the news for display.
                                        var smfFadeContent = new Array(
                                                "', implode('",
                                                "', $context['fader_news_lines']), '"
                                        );
                                // --></script>
                                <script language="JavaScript1.2" type="text/javascript" src="', $settings['default_theme_url'], '/fader.js"></script>
                        </td>
                </tr>
        </table>
</div>';
echo $botbox;
        }

        /* Each category in categories is made up of:
                id, href, link, name, is_collapsed (is it collapsed?), can_collapse (is it okay if it is?),
                new (is it new?), collapse_href (href to collapse/expand), collapse_image (up/down iamge),
                and boards. (see below.) */
        echo $topbox;
        foreach ($context['categories'] as $category)
        {
                echo '
<div class="tborder"><table border="0" width="100%" cellspacing="1" cellpadding="6">
        <tr>
                <td colspan="2" class="catbg', $category['new'] ? '2' : '', '" height="18">';

                // If this category even can collapse, show a link to collapse it.
                if ($category['can_collapse'])
                        echo '
                        <a href="', $category['collapse_href'], '">', $category['collapse_image'], '</a>';

                echo '
                        ', $category['link'], '
                </td>
                <td width="4%" class="catbg', $category['new'] ? '2' : '', '"><b>' ,$txt[21], '</b></td>
                <td width="4%" class="catbg', $category['new'] ? '2' : '', '"><b>' ,$txt[330], '</b></td>
                <td width="22%" align="center" class="catbg', $category['new'] ? '2' : '', '"> ', $txt[22], '</td>
        </tr>';

                // Assuming the category hasn't been collapsed...
                if (!$category['is_collapsed'])
                {
                        /* Each board in each category's boards has:
                                new (is it new?), id, name, description, moderators (see below), link_moderators (just a list.),
                                children (see below.), link_children (easier to use.), children_new (are they new?),
                                topics (# of), posts (# of), link, href, and last_post. (see below.) */
                        foreach ($category['boards'] as $board)
                        {
                                echo '
        <tr class="windowbg2">
                <td class="windowbg" width="6%" align="center" valign="top">';

                                // If the board is new, show a strong indicator.
                                if ($board['new'])
                                        echo '<img src="', $settings['images_url'], '/on.gif" alt="', $txt[333], '" title="', $txt[333], '" border="0" />';
                                // This board doesn't have new posts, but its children do.
                                elseif ($board['children_new'])
                                        echo '<img src="', $settings['images_url'], '/on2.gif" alt="', $txt[333], '" title="', $txt[333], '" border="0" />';
                                // No new posts at all!  The agony!!
                                else
                                        echo '<img src="', $settings['images_url'], '/off.gif" alt="', $txt[334], '" title="', $txt[334], '" border="0" />';

                                echo '</td>
                <td align="left">
                        <b><a href="', $board['href'], '" name="b', $board['id'], '">', $board['name'], '</a></b><br />
                        ', $board['description'];

                                // Show the "Moderators: ".  Each has name, href, link, and id. (but we're gonna use link_moderators.)
                                if (!empty($board['moderators']))
                                        echo '
                        <div style="padding-top: 1px;" class="smalltext"><i>', count($board['moderators']) == 1 ? $txt[298] : $txt[299], ': ', implode(', ', $board['link_moderators']), '</i></div>';

                                // Show the "Child Boards: ". (there's a link_children but we're going to bold the new ones...)
                                if (!empty($board['children']))
                                {
                                        // Sort the links into an array with new boards bold so it can be imploded.
                                        $children = array();
                                        /* Each child in each board's children has:
                                                id, name, description, new (is it new?), topics (#), posts (#), href, link, and last_post. */
                                        foreach ($board['children'] as $child)
                                        {
                                                $child['link'] = '<a href="' . $child['href'] . '" title="' . ($child['new'] ? $txt[333] : $txt[334]) . ' (' . $txt[330] . ': ' . $child['topics'] . ', ' . $txt[21] . ': ' . $child['posts'] . ')">' . $child['name'] . '</a>';
                                                $children[] = $child['new'] ? '<b>' . $child['link'] . '</b>' : $child['link'];
                                        }

                                        echo '
                        <div style="padding-top: 1px;" class="smalltext"><i>', $txt['parent_boards'], ': ', implode(', ', $children), '</i></div>';
                                }

                                // Show some basic information about the number of posts, etc.
                                echo '
                </td>
                <td class="windowbg" valign="middle" align="center" style="width: 8ex;"><span class="smalltext">
                        ', $board['posts'], '</span></td>
                <td class="windowbg" valign="middle" align="center" style="width: 8ex;"><span class="smalltext">
                        ', $board['topics'],'
                </span></td>
                <td class="smalltext" valign="middle" width="25%" style="padding-left: 12px;">';

                                /* The board's and children's last_post's have:
                                        time, timestamp (a number that represents the time.), id (of the post), topic (topic id.),
                                        link, href, subject, start (where they should go for the first unread post.),
                                        and member. (which has id, name, link, href, username in it.) */
                                if (!empty($board['last_post']['id']))
                                        echo $board['last_post']['time'], '<br />
                       <b>', $board['last_post']['link'], '</b> ', $txt[525], '
                       ', $board['last_post']['member']['link'];

                                echo '
                </td>
        </tr>';
                        }
                }

                echo '
</table></div>';
        }

        echo $botbox;

        echo $leftboxbot;
        if ($context['user']['is_logged'])
        {
                echo '
<div style="padding-top: 16px;"><table border="0" width="100%" cellspacing="0" cellpadding="0" valign="top">
        <tr>
                <td align="left" class="smalltext" valign="top">
                        <img src="' . $settings['images_url'] . '/new_some.gif" alt="" align="absmiddle" border="0" /> ', $txt[333], '
                        <img src="' . $settings['images_url'] . '/new_none.gif" alt=""  align="absmiddle" border="0" style="margin-left: 4ex;" /> ', $txt[334], '
                </td>
                <td align="right" class="smalltext">';
                // Show the mark all as read button?
                if ($settings['show_mark_read'])
                        echo '
                        <a href="', $scripturl, '?action=markasread;sa=all">', ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/markread.gif" alt="' . $txt[452] . '" border="0" />' : $txt[452]), '</a>';
                echo '
                </td>
        </tr>
</table></div>';
        }
        else
           echo '<div style="padding: 0px;"><table border="0" width="100%" cellspacing="0" cellpadding="5">
        <tr>
                <td align="left" class="smalltext">

                </td>
                <td align="right" class="smalltext">
                </td>
        </tr>
</table></div>';
echo $rightboxbot;

        // Here's where the "Info Center" starts...

       echo $leftboxbot2.'<div style="font-weight: bold; text-align: center;">'.$txt[685].'</div>'.$rightboxbot2;

       echo '<div style="padding-left: 0px; padding-right: 0px;">'.$topbox;
       echo '

<div class="tborder"><table border="0" width="100%" cellspacing="1" cellpadding="4"> ';

        // This is the "Recent Posts" bar.
        if (!empty($settings['number_recent_posts']))
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[214], '</td>
        </tr>
        <tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                        <a href="', $scripturl, '?action=recent">
                                <img src="', $settings['images_url'], '/post/xx.gif" alt="', $txt[214], '" border="0" /></a>
                </td>
                <td class="windowbg2">';

                // Only show one post.
                if ($settings['number_recent_posts'] == 1)
                {
                        // latest_post has link, href, time, subject, short_subject (shortened with...), and topic. (it's id.)
                        echo '
                        <b><a href="', $scripturl, '?action=recent">', $txt[214], '</a></b>
                        <div class="smalltext">
                                ', $txt[234], ' &quot;', $context['latest_post']['link'], '&quot; ', $txt[235], ' (', $context['latest_post']['time'], ')<br />
                        </div>';
                }
                // Show lots of posts.
                elseif (!empty($context['latest_posts']))
                {
                        echo '
                        <table width="100%" border="0">';
                        /* Each post in latest_posts has:
                                board (with an id, name, and link.), topic (the topic's id.), poster (with id, name, and link.),
                                subject, short_subject (shortened with...), time, link, and href. */
                        foreach ($context['latest_posts'] as $post)
                                echo '
                                <tr>
                                        <td class="smalltext" align="right" valign="top" nowrap="nowrap">[', $post['board']['link'], ']</td>
                                        <td class="smalltext" valign="top">', $post['link'], ' ', $txt[525], ' ', $post['poster']['link'], '</td>
                                        <td class="smalltext" align="right" valign="top" nowrap="nowrap">', $post['time'], '</td>
                                </tr>';
                        echo '
                        </table>';
                }
                echo '
                </td>
        </tr>';
        }

        // Show information about events, birthdays, and holidays on the calendar.
        if ($context['show_calendar'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $context['calendar_only_today'] ? $txt['calendar47b'] : $txt['calendar47'], '</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                        <a href="', $scripturl, '?action=calendar">
                                <img src="', $settings['images_url'], '/icons/calendar.gif" width="20" alt="', $txt['calendar24'], '" border="0" /></a>
                </td>
                <td class="windowbg2" width="100%">
                        <span class="smalltext">';

                // Holidays like "Christmas", "Chanukah", and "We Love [Unknown] Day" :P.
                if (!empty($context['calendar_holidays']))
                        echo '
                                <span style="color: #', $modSettings['cal_holidaycolor'], ';">', $txt['calendar5'], ' ', implode(', ', $context['calendar_holidays']), '</span><br />';

                // People's birthdays.  Like mine.  And yours, I guess.  Kidding.
                if (!empty($context['calendar_birthdays']))
                {
                        echo '
                                <span style="color: #', $modSettings['cal_bdaycolor'], ';">', $context['calendar_only_today'] ? $txt['calendar3'] : $txt['calendar3b'], '</span> ';
                        /* Each member in calendar_birthdays has:
                                id, name (person), age (if they have one set?), is_last. (last in list?), and is_today (birthday is today?) */
                        foreach ($context['calendar_birthdays'] as $member)
                                echo '
                                <a href="', $scripturl, '?action=profile;u=', $member['id'], '">', $member['is_today'] ? '<b>' : '', $member['name'], $member['is_today'] ? '</b>' : '', isset($member['age']) ? ' (' . $member['age'] . ')' : '', '</a>', $member['is_last'] ? '<br />' : ', ';
                }
                // Events like community get-togethers.
                if (!empty($context['calendar_events']))
                {
                        echo '
                                <span style="color: #', $modSettings['cal_eventcolor'], ';">', $context['calendar_only_today'] ? $txt['calendar4'] : $txt['calendar4b'], '</span> ';
                        /* Each event in calendar_events should have:
                                title, href, is_last, can_edit (are they allowed?), modify_href, and is_today. */
                        foreach ($context['calendar_events'] as $event)
                                echo '
                                ', $event['can_edit'] ? '<a href="' . $event['modify_href'] . '" style="color: #FF0000;">*</a> ' : '', '<a href="', $event['href'], '">', $event['is_today'] ? '<b>' . $event['title'] . '</b>' : $event['title'], '</a>', $event['is_last'] ? '<br />' : ', ';

                        // Show a little help text to help them along ;).
                        if ($context['calendar_can_edit'])
                                echo '
                                (<a href="', $scripturl, '?action=helpadmin;help=calendar_how_edit" onclick="return reqWin(this.href);">', $txt['calendar_how_edit'], '</a>)';
                }
                echo '
                        </span>
                </td>
        </tr>';
        }

        // Show a member bar.  Not heavily ornate, but functional at least.
        if ($settings['show_member_bar'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[331], '</td>
        </tr>
        <tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                        <a href="', $scripturl, '?action=mlist">
                                <img src="', $settings['images_url'], '/icons/members.gif" width="20" alt="', $txt[332], '" border="0" /></a>
                </td>
                <td class="windowbg2" width="100%">
                        <b><a href="', $scripturl, '?action=mlist">', $txt[332], '</a></b>
                        <div class="smalltext">', $txt[200], '</div>
                </td>
        </tr>';
        }

        // Show YaBB SP1 style information...
        if ($settings['show_sp1_info'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[645], '</td>
        </tr>
        <tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                        <a href="', $scripturl, '?action=stats">
                                <img src="', $settings['images_url'], '/icons/info.gif" alt="', $txt[645], '" border="0" /></a>
                </td>
                <td class="windowbg2" width="100%">
                        <table border="0" width="90%"><tr>
                                <td class="smalltext">
                                        <div style="float: left; width: 50%;">', $txt[490], ': <b>', $modSettings['totalTopics'], '</b></div>', $txt[489], ': <b>', $modSettings['totalMessages'], '</b><br />', !empty($context['latest_post']) ? '
                                        ' . $txt[659] . ': &quot;' . $context['latest_post']['link'] . '&quot;  (' . $context['latest_post']['time'] . ')<br />' : '', '
                                        <a href="', $scripturl, '?action=recent">', $txt[234], '</a>', $context['show_stats'] ? '<br />
                                        <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
                                </td>
                                <td width="32%" class="smalltext" valign="top">
                                        ', $txt[656], ': <b>', $context['latest_member']['link'], '</b><br />';
                // If they are logged in, show their unread message count, etc..
                if ($context['user']['is_logged'])
                        echo '
                                        ', $txt['smf199'], ': <b><a href="', $scripturl, '?action=pm">', $context['user']['messages'], '</a></b> ', $txt['newmessages3'], ': <b><a href="', $scripturl, '?action=pm">', $context['user']['unread_messages'], '</a></b>';
                echo '
                                </td>
                        </tr></table>
                </td>
        </tr>';
        }
        // Chat Stats
        if(isset($modSettings['chatLanguage']))
        echo '
        <tr>
                <td class="titlebg" colspan="2"></td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                </td>
                <td class="windowbg2" width="100%">
                        Mire las estadísticas, pueden resultarle interesantes .<br />

                        <span class="smalltext">';

        // "Users online" - in order of activity.
        echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[158], '</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                        <a href="', $scripturl, '?action=who">
                                <img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], '" border="0" /></a>
                </td>
                <td class="windowbg2" width="100%">
                        <a href="', $scripturl, '?action=who">', $context['num_guests'], ' ', $context['num_guests'] == 1 ? $txt['guest'] : $txt['guests'], ', ', $context['num_users_online'], ' ', $context['num_users_online'] == 1 ? $txt['user'] : $txt['users'], (empty($context['num_users_hidden']) ? '' : ' (' . $context['num_users_hidden'] . ' ' . $txt['hidden'] . ')'), '</a><br />
                        <span class="smalltext">';

        // Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
        if (!empty($context['users_online']))
                echo '
                                ', $txt[140], ':<br />', implode(', ', $context['list_users_online']);

        echo '
                                <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
                                <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
                        </span>
                        <hr /><span class="smalltext">
                        Mayor cantidad de usuarios conectados al mismo tiempo hoy: '.$modSettings['mostOnlineToday'].' &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

                        </span>


                </td>
        </tr>';

        // "Users online Today"
        if(isset($context['num_users_today']))
        echo '
        <tr>
                <td class="catbg" colspan="2">', ' ( ', $context['num_users_today'], ' ', $context['num_users_today'] == 1 ? $txt['user'] : $txt['users'], ' )</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                <td class="windowbg2" width="100%"><span class="smalltext">', $context['user_today'], '</span></td>
        </tr>';

        // If they are logged in, but SP1 style information is off... show a personal message bar.
        if ($context['user']['is_logged'] && !$settings['show_sp1_info'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[159], '</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                        <a href="', $scripturl, '?action=pm">
                                <img src="', $settings['images_url'], '/message_sm.gif" alt="', $txt[159], '" border="0" /></a>
                </td>
                <td class="windowbg2" valign="top">
                        <b><a href="', $scripturl, '?action=pm">', $txt[159], '</a></b>
                        <div class="smalltext">
                                ', $txt[660], ' ', $context['user']['messages'], ' ', $context['user']['messages'] == 1 ? $txt[471] : $txt[153], '.... ', $txt[661], ' <a href="', $scripturl, '?action=pm">', $txt[662], '</a> ', $txt[663], '
                        </div>
                </td>
        </tr>';
        }

        // Show the login bar. (it's only true if they are logged out anyway.)
        if ($context['show_login_bar'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[34], ' <a href="', $scripturl, '?action=reminder" class="smalltext">(' . $txt[315] . ')</a></td>
        </tr>
        <tr>
                <td class="windowbg" width="20" align="center">
                        <a href="', $scripturl, '?action=login">
                                <img src="', $settings['images_url'], '/icons/login.gif" alt="', $txt[34], '" border="0" /></a>
                </td>
                <td class="windowbg2" valign="middle">
                        <form action="', $scripturl, '?action=login2" method="post" style="margin: 0;">
                                <table border="0" cellpadding="2" cellspacing="0" align="center" width="100%"><tr>
                                        <td valign="middle" align="left">
                                                <label for="user"><b>', $txt[35], ':</b><br /><input type="text" name="user" id="user" size="15" /></label>
                                        </td>
                                        <td valign="middle" align="left">
                                                <label for="passwrd"><b>', $txt[36], ':</b><br /><input type="password" name="passwrd" id="passwrd" size="15" /></label>
                                        </td>
                                        <td valign="middle" align="left">
                                                <label for="cookielength"><b>', $txt[497], ':</b><br /><input type="text" name="cookielength" id="cookielength" size="4" maxlength="4" value="', $modSettings['cookieTime'], '" /></label>
                                        </td>
                                        <td valign="middle" align="left">
                                                <label for="cookieneverexp"><b>', $txt[508], ':</b><br /><input type="checkbox" name="cookieneverexp" id="cookieneverexp" checked="checked" class="check" /></label>
                                        </td>
                                        <td valign="middle" align="left">
                                                <input type="submit" value="', $txt[34], '" /&
Title: Re: Users Online Today Mod
Post by: beemer on December 04, 2005, 04:27:02 PM
Quote from: diegolyanky on December 04, 2005, 03:27:27 PM
Good mod, but:

I installed, and I modified files of my theme helios_multi manually and doesn't work ...

I uninstalled old User Online Today mod ...

                                   <input type="submit" value="', $txt[34], '" /&g

You uninstalled the old version?

From the template you just posted you are running smf 1.03 so you need the old version !!
Title: Re: Users Online Today Mod
Post by: diegolyanky on December 04, 2005, 04:39:11 PM
No, is 1.1RC1 ... I have downloaded and installed helios_multi premod long time ago. So, I think what Bloc ( Bloc is helios_multi creator ) just forget to change from 1.0.3 to 1.1rc1 ... But the code is actualiced for working with SMF 1.1rc1

Resumming: " I have al files up to date " and I wanna to install this mod on my forum. remember what my forum use helios_multi as Default Community Theme .

Many thanks for you reply !  ;)
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on December 04, 2005, 04:45:11 PM
Helios Multi premod doesn't work with rc1....

Title: Re: Users Online Today Mod
Post by: SoaringUSAEagle on December 04, 2005, 08:07:18 PM
I'm lost on how to install this... any help is appreciated.  I am running 1.1 RC1
Title: Re: Users Online Today Mod
Post by: diegolyanky on December 04, 2005, 09:11:01 PM
Quote from: Libo on December 04, 2005, 04:45:11 PM
Helios Multi premod doesn't work with rc1....



What ?

Helios-multi premod is the helios_multi files modified for working with users online today and other mods.

Helios_multi premod is working on my forum long time ... And works fine !


Title: Re: Users Online Today Mod
Post by: DemonicInfluence on December 05, 2005, 07:22:32 AM
I know. it isn't supposed to work on rc1.. It is for 1.0.5 only..
Title: Re: Users Online Today Mod
Post by: Menni on December 05, 2005, 01:07:38 PM
I have this mod installed to my forum. How can I have text "x users online today" chanced to my own language(finnish)?
Title: Re: Users Online Today Mod
Post by: Owdy on December 05, 2005, 05:05:24 PM

Menni, translate these and put them to Modifications.finnish.php

$txt['uot_users_online_today_title']='Users Online Today';
$txt['uot_user_online_today']='user online today';
$txt['uot_users_online_today']='users online today';
$txt['uot_total_users_online_today']='Total Online Today';
$txt['uot_yesterday']='Yesterday at ';
Title: Re: Users Online Today Mod
Post by: RoarinRow on December 10, 2005, 06:11:44 PM
I finally got this to work on my forum SMF 1.0.5.

1.  I downloaded the file from FaSan's website (Registration required to get to download section).  After your register, you should logout, then log back in again to see the contents of the download section.

     http://www.smitalia.net/community/index.php

2.  Download and install OnLineUserToday_13_10.zip via Package Manager

3.  Edit your 'BoardIndexTemplate' for your custom them. 

I had to change the highlighted code from 'titlebg' to 'catgb' to go with my Techhead theme.

// "Users online Today"
        if(isset($context['num_users_today']))
        echo '
        <tr>
                <td class="catbg" colspan="2">', $txt['158bis'], ' ( ', $context['num_users_today'], ' ', $context['num_users_today'] == 1 ? $txt['user'] : $txt['users'], ' )</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center"><img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['158bis'], '" border="0" /></td>
                <td class="windowbg2" width="100%"><span class="smalltext">', $context['user_today'], '</span></td>
        </tr>';

That's it.  It put's the member's names in alphabetical order.
Title: Re: Users Online Today Mod
Post by: ToyDozer on December 11, 2005, 12:42:35 AM
Very nice! Took me a bit but I got it going on SMF 1.0.5 using Helios_Multi theme!

Thanks go out to everyone involved!

Take a peak at Wheeling Adventures (http://www.wheelingadventures.com/Board)
Title: Re: Users Online Today Mod
Post by: Maycomb on December 11, 2005, 10:29:57 PM
This may sound stupid, but where do you install this to?
Title: Re: Users Online Today Mod
Post by: RoarinRow on December 11, 2005, 11:38:48 PM
Quote from: Maycomb on December 11, 2005, 10:29:57 PM
This may sound stupid, but where do you install this to?

I installed the zip file via the Package Manager through the Admin section of your forum.
Title: Re: Users Online Today Mod
Post by: jerm on December 12, 2005, 11:40:20 AM
i would like to go about removing myself from the "Users Online Today" list. how would i go about doing this?
Title: Re: Users Online Today Mod
Post by: L.G.S on December 12, 2005, 12:01:46 PM
Any idea when I try to install it with any skin other than default it re arranges my skin?
Title: Re: Users Online Today Mod
Post by: RoarinRow on December 12, 2005, 12:34:58 PM
Quote from: electrohome88 on December 12, 2005, 11:40:20 AM
i would like to go about removing myself from the "Users Online Today" list. how would i go about doing this?

Don't think you can.  Once you log on it captures your information and puts you on the list.
Title: Re: Users Online Today Mod
Post by: RoarinRow on December 12, 2005, 12:38:29 PM
Quote from: The Outsider on December 12, 2005, 12:01:46 PM
Any idea when I try to install it with any skin other than default it re arranges my skin?

The fix I used was for SMF 1.0.5.   Not sure why it would re-arrange your skin unless it was something from this mod from Carceri.
Title: *Insert Month here* dissapeared from Stats
Post by: L.G.S on December 13, 2005, 11:44:32 AM
I have only added Users Online Today mod, which has been up for 2 weeks and had no previous problems.

At the bottom where it is supposed to say :

December
November
October
September

Etc,

it just shows

2005
2005

etc
Title: Re: Users Online Today Mod
Post by: Carceri on December 13, 2005, 04:12:51 PM
"At the bottom". Could you be more specific?

If you are refering to the Fasan mod, please state it clearly or do so in another thread. It makes it easier for me to respond to problems about my mod if I know that people posting in this thread is actually referring to my mod :)
Title: Re: Users Online Today Mod
Post by: L.G.S on December 14, 2005, 04:46:50 PM
At the bottom as in the bottom area of the stats where the hits/posts/members per day is kept.
Title: Re: Users Online Today Mod
Post by: Skipdawg on December 14, 2005, 07:45:09 PM
 ???

OK have gone through this thread twice and used the search too.
Is there a place to download this Mod for 1.0.5 that is a English language site. I get to the other mentioned here and get stuck for I can't read it.  ::)
Title: Re: Users Online Today Mod
Post by: beemer on December 15, 2005, 04:49:20 AM
Quote from: Skipdawg on December 14, 2005, 07:45:09 PM
???

OK have gone through this thread twice and used the search too.
Is there a place to download this Mod for 1.0.5 that is a English language site. I get to the other mentioned here and get stuck for I can't read it.  ::)

Here is the old 1.05 version

http://www.simplemachines.org/community/index.php?topic=20168.msg345586#msg345586
Title: Re: Users Online Today Mod
Post by: Skipdawg on December 15, 2005, 01:32:57 PM
beemer thanks  ;)
Got and it loaded fine.
kewl Mod!  8)
Title: Re: Users Online Today Mod
Post by: Stuart on December 27, 2005, 12:23:11 PM
I wish I could get this MOD working on my forum but all I get are some errors  :'(
I'm not using a default theme and my language is Dutch  :(
Title: Re: Users Online Today Mod
Post by: ASi ve MAVi on December 28, 2005, 06:55:33 AM
my dear frıend,ı have opened this mod download my web page.ıs ıt ok for you?

http://www.guzelforum.com/forum/index.php/board,70.0.html

sorry I don't english speak too
Title: Re: Users Online Today Mod
Post by: Stuart on December 28, 2005, 12:04:11 PM
Quote from: ASi ve MAVi on December 28, 2005, 06:55:33 AM
my dear frıend,ı have opened a mod ın whıch you had.ıs ıt ok for you?

http://www.guzelforum.com/forum/index.php/board,70.0.html

sorry I don't english speak too

Thanks for offering your help, though I don't get any further by visiting your website  :( Nevertheless it's appreciated that you tried  ;D

If anyone can help me how I can actually get this MOD working on my forum that would be very kind !

Cheers,
Stuart
Title: Re: Users Online Today Mod
Post by: ASi ve MAVi on December 28, 2005, 01:05:49 PM
1.1RC1 FOR MANUEL SETUP


SOURCE directory BoardIndex.php file chance


find


mysql_free_result($result_boards);

after to add

// Load the users online today.
$nowdate = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);

$s = strpos($user_info['time_format'], '%S') === false ? '' : ':%S';
if (strpos($user_info['time_format'], '%H') === false && strpos($user_info['time_format'], '%T') === false)
$time_fmt = '%I:%M' . $s . ' %p';
else
$time_fmt = '%H:%M' . $s;

$result = db_query("
SELECT
mem.ID_MEMBER, mem.lastLogin, mem.realName, mem.memberName, mem.showOnline,
mg.onlineColor, mg.ID_GROUP, mg.groupName
FROM {$db_prefix}members AS mem
LEFT JOIN {$db_prefix}membergroups AS mg ON (mg.ID_GROUP = IF(mem.ID_GROUP = 0, mem.ID_POST_GROUP, mem.ID_GROUP)) WHERE mem.lastLogin >= $midnight", __FILE__, __LINE__);

$context['users_online_today'] = array();
$context['list_users_online_today'] = array();

while ($row = mysql_fetch_assoc($result))
{
$userday = strftime('%d', forum_time(true));
$loginday = strftime('%d', forum_time(true, $row['lastLogin']));
$yesterday = $userday == $loginday ? '' : $txt['uot_yesterday'];

$lastLogin = $yesterday . strftime($time_fmt, forum_time(true, $row['lastLogin']));
$title = (allowedTo('moderate_forum') || !empty($row['showOnline'])) ? ' title="' . $lastLogin . '"' : '';

// Some basic color coding...
if (!empty($row['onlineColor']))
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['ID_MEMBER'] . '"' . $title . ' style="color: ' . $row['onlineColor'] . ';">' . $row['realName'] . '</a>';
else
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['ID_MEMBER'] . '"' . $title . '>' . $row['realName'] . '</a>';

$is_buddy = in_array($row['ID_MEMBER'], $user_info['buddies']);
if ($is_buddy)
{
$link = '<b>' . $link . '</b>';
}

$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
'id' => $row['ID_MEMBER'],
'username' => $row['memberName'],
'name' => $row['realName'],
'group' => $row['ID_GROUP'],
'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
'link' => $link,
'is_buddy' => $is_buddy,
'hidden' => empty($row['showOnline']),
);

$context['list_users_online_today'][$row['lastLogin'] . $row['memberName']] = (empty($row['showOnline']) && allowedTo('moderate_forum')) ? '<i>' . $link . '</i>' : $link;
}
mysql_free_result($result);

krsort($context['users_online_today']);
krsort($context['list_users_online_today']);

$context['num_users_online_today'] = count($context['users_online_today']);





SOURCE directory Stats.php file chance

find


$context['online_today'] = (int) $context['online_today'];

after to add

// Total members online today
$frag = explode('-', strftime('%Y-%m-%d', time()));
$midnight = forum_time(false, mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]));
$result = db_query("
SELECT
COUNT(*)
FROM {$db_prefix}members
WHERE lastLogin >= $midnight", __FILE__, __LINE__);
list ($context['total_users_online_today']) = mysql_fetch_row($result);





yours theme BoardIndex.template.php file chance

find


<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


after to add


// Users online today
echo '
<tr>
<td class="catbg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';





yours theme Stats.template.php file chance

find


<td nowrap="nowrap">', $txt['users_online_today'], ':</td>
<td align="right">', $context['online_today'], '</td>';


remove and add

<td nowrap="nowrap">', $txt['users_online_today'], ':</td>
<td align="right">', $context['online_today'], '</td>
</tr><tr>
<td nowrap="nowrap">', $txt['uot_total_users_online_today'], ':</td>
<td align="right">', $context['total_users_online_today'], '</td>';





DEFAULT Theme LANGUAGES directory Modifications.english.php file chance

?>

over to add

$txt['uot_users_online_today_title']='Users Online Today';
$txt['uot_user_online_today']='user online today';
$txt['uot_users_online_today']='users online today';
$txt['uot_total_users_online_today']='Total Online Today';
$txt['uot_yesterday']='Yesterday at ';

Title: Re: Users Online Today Mod
Post by: Stuart on December 28, 2005, 01:21:03 PM
I'm still using SMF 1.0.5.  :-[
Title: Re: Users Online Today Mod
Post by: ASi ve MAVi on December 28, 2005, 03:46:15 PM
1,0,5 different
Title: Re: Users Online Today Mod
Post by: beemer on December 28, 2005, 04:31:07 PM
Stuart ?

Did you install the 1.05 version?

What are the errors you are getting?
Title: Re: Users Online Today Mod
Post by: Stuart on December 28, 2005, 04:43:59 PM
Quote from: beemer on December 28, 2005, 04:31:07 PM
Stuart ?

Did you install the 1.05 version?

What are the errors you are getting?

I may actually have used the wrong version of this MOD  ???
Title: Re: Users Online Today Mod
Post by: beemer on December 28, 2005, 04:46:34 PM
See if you can uninstall and try the versio in the link on my post 2 above?
Title: Re: Users Online Today Mod
Post by: Stuart on December 28, 2005, 04:54:48 PM
Quote from: beemer on December 28, 2005, 04:46:34 PM
See if you can uninstall and try the versio in the link on my post 2 above?

I'm ever so sorry, but that seems to be the location MOD  ???
I already tried that but what has it got to do with the Online Today MOD  ???
Sorry for not understanding, I possibly look like a pretty dumb guy now  :(
Title: Re: Users Online Today Mod
Post by: beemer on December 28, 2005, 05:12:28 PM
Stuart sorry  (that was for someting else) doh

The latest version says for 1.1 rc1 I cant find an old copy maybe on my works pc?

What are the errors you get?
Title: Re: Users Online Today Mod
Post by: Stuart on December 28, 2005, 05:40:26 PM
Quote from: beemer on December 28, 2005, 05:12:28 PM
Stuart sorry  (that was for someting else) doh

The latest version says for 1.1 rc1 I cant find an old copy maybe on my works pc?

What are the errors you get?

I should find myself the 1.0.5. version I guess  :P

1. Voer aanpassing uit ./Sources/BoardIndex.php Succes
2. Voer aanpassing uit ./Sources/Stats.php Failed
3. Voer aanpassing uit ./Themes/default/BoardIndex.template.php Failed
4. Voer aanpassing uit ./Themes/default/Stats.template.php Failed
5. Voer aanpassing uit ./Themes/default/languages/Modifications.english.php Failed
6. Voer aanpassing uit ./Themes/default/languages/Stats.english.php Failed

2: in_array(): Wrong datatype for second argument
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Sources/BoardIndex.php
Regel: 274

8: Undefined index: buddies
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Sources/BoardIndex.php
Regel: 274
Title: Re: Users Online Today Mod
Post by: Stuart on December 28, 2005, 06:13:47 PM
Quote from: RoarinRow on December 10, 2005, 06:11:44 PM
I finally got this to work on my forum SMF 1.0.5.

1.  I downloaded the file from FaSan's website (Registration required to get to download section).  After your register, you should logout, then log back in again to see the contents of the download section.

     http://www.smitalia.net/community/index.php

2.  Download and install OnLineUserToday_13_10.zip via Package Manager

3.  Edit your 'BoardIndexTemplate' for your custom them. 

I had to change the highlighted code from 'titlebg' to 'catgb' to go with my Techhead theme.

// "Users online Today"
        if(isset($context['num_users_today']))
        echo '
        <tr>
                <td class="catbg" colspan="2">', $txt['158bis'], ' ( ', $context['num_users_today'], ' ', $context['num_users_today'] == 1 ? $txt['user'] : $txt['users'], ' )</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center"><img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['158bis'], '" border="0" /></td>
                <td class="windowbg2" width="100%"><span class="smalltext">', $context['user_today'], '</span></td>
        </tr>';

That's it.  It put's the member's names in alphabetical order.

I tried all that but I'm getting these errors:

8: Undefined index: 158bis
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Themes/safblue105/BoardIndex.template.php (eval?)
Regel: 362


8: Undefined index: 158bis
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Themes/safblue105/BoardIndex.template.php (eval?)
Regel: 364


I have to put my account into English, otherwise it's not working and it looks like a mess when you view the stats page (if you're using the Dutch language)  :'(

8: Undefined index: smf_stats_14bis
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Themes/default/languages/Stats.dutch.php (eval?)
Regel: 181
Title: Re: Users Online Today Mod
Post by: Stuart on December 28, 2005, 06:48:16 PM
Quote from: RoarinRow on December 28, 2005, 06:24:02 PM
Quote from: Stuart on December 28, 2005, 06:13:47 PM
Quote from: RoarinRow on December 10, 2005, 06:11:44 PM
I finally got this to work on my forum SMF 1.0.5.

1.  I downloaded the file from FaSan's website (Registration required to get to download section).  After your register, you should logout, then log back in again to see the contents of the download section.

     http://www.smitalia.net/community/index.php

2.  Download and install OnLineUserToday_13_10.zip via Package Manager

3.  Edit your 'BoardIndexTemplate' for your custom them. 

I had to change the highlighted code from 'titlebg' to 'catgb' to go with my Techhead theme.

// "Users online Today"
        if(isset($context['num_users_today']))
        echo '
        <tr>
                <td class="catbg" colspan="2">', $txt['158bis'], ' ( ', $context['num_users_today'], ' ', $context['num_users_today'] == 1 ? $txt['user'] : $txt['users'], ' )</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center"><img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['158bis'], '" border="0" /></td>
                <td class="windowbg2" width="100%"><span class="smalltext">', $context['user_today'], '</span></td>
        </tr>';

That's it.  It put's the member's names in alphabetical order.

I tried all that but I'm getting these errors:

8: Undefined index: 158bis
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Themes/safblue105/BoardIndex.template.php (eval?)
Regel: 362


8: Undefined index: 158bis
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Themes/safblue105/BoardIndex.template.php (eval?)
Regel: 364


I have to put my account into English, otherwise it's not working and it looks like a mess when you view the stats page (if you're using the Dutch language)  :'(

I have the file here - OnLineUserToday (http://www.avalanchestyle.com/forum/AVS/OnLineUserToday_13_10.zip)

I resolved those errors by going to my 'Modifications.english.php file' found at Themes/default/languages and adding this line:

//OnLine Users Today
$txt['158bis'] = 'Users Online Today';
$txt['smf_stats_14bis'] = 'Users Online Today';



It worked, thanks for your help  :D
Title: Re: Users Online Today Mod
Post by: RoarinRow on December 28, 2005, 06:49:23 PM
Quote from: Stuart on December 28, 2005, 06:48:16 PM
Quote from: RoarinRow on December 28, 2005, 06:24:02 PM
Quote from: Stuart on December 28, 2005, 06:13:47 PM
Quote from: RoarinRow on December 10, 2005, 06:11:44 PM
I finally got this to work on my forum SMF 1.0.5.

1.  I downloaded the file from FaSan's website (Registration required to get to download section).  After your register, you should logout, then log back in again to see the contents of the download section.

     http://www.smitalia.net/community/index.php

2.  Download and install OnLineUserToday_13_10.zip via Package Manager

3.  Edit your 'BoardIndexTemplate' for your custom them. 

I had to change the highlighted code from 'titlebg' to 'catgb' to go with my Techhead theme.

// "Users online Today"
        if(isset($context['num_users_today']))
        echo '
        <tr>
                <td class="catbg" colspan="2">', $txt['158bis'], ' ( ', $context['num_users_today'], ' ', $context['num_users_today'] == 1 ? $txt['user'] : $txt['users'], ' )</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center"><img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['158bis'], '" border="0" /></td>
                <td class="windowbg2" width="100%"><span class="smalltext">', $context['user_today'], '</span></td>
        </tr>';

That's it.  It put's the member's names in alphabetical order.

I tried all that but I'm getting these errors:

8: Undefined index: 158bis
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Themes/safblue105/BoardIndex.template.php (eval?)
Regel: 362


8: Undefined index: 158bis
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Themes/safblue105/BoardIndex.template.php (eval?)
Regel: 364


I have to put my account into English, otherwise it's not working and it looks like a mess when you view the stats page (if you're using the Dutch language)  :'(

I resolved those errors by going to my 'Modifications.english.php file' found at Themes/default/languages and adding this line:

//OnLine Users Today
$txt['158bis'] = 'Users Online Today';
$txt['smf_stats_14bis'] = 'Users Online Today';



It worked, thanks for your help  :D

Welcome!
Title: Re: Users Online Today Mod
Post by: California Dreamin on December 29, 2005, 02:28:02 AM
I have installed this and it is not showing up on my board. How do you activate it?
I have logged out and back in. Still not showing up.
Title: Re: Users Online Today Mod
Post by: RoarinRow on December 29, 2005, 02:36:00 AM
Quote from: fresnolady on December 29, 2005, 02:28:02 AM
I have installed this and it is not showing up on my board. How do you activate it?
I have logged out and back in. Still not showing up.

I used the edit to my custom BoardIndexTemplate.php as described above for my SMF v.1.0.5 forum.  The mod should work for the Default theme, but anything else will require modification to your BoardIndexTemplate.php for your version of SMF.
Title: Re: Users Online Today Mod
Post by: California Dreamin on December 30, 2005, 12:27:53 AM
Quote from: RoarinRow on December 29, 2005, 02:36:00 AM
Quote from: fresnolady on December 29, 2005, 02:28:02 AM
I have installed this and it is not showing up on my board. How do you activate it?
I have logged out and back in. Still not showing up.

I used the edit to my custom BoardIndexTemplate.php as described above for my SMF v.1.0.5 forum.  The mod should work for the Default theme, but anything else will require modification to your BoardIndexTemplate.php for your version of SMF.

I am using the Default theme  :(
Title: Re: Users Online Today Mod
Post by: RoarinRow on December 30, 2005, 12:46:19 AM
Quote from: fresnolady on December 30, 2005, 12:27:53 AM
Quote from: RoarinRow on December 29, 2005, 02:36:00 AM
Quote from: fresnolady on December 29, 2005, 02:28:02 AM
I have installed this and it is not showing up on my board. How do you activate it?
I have logged out and back in. Still not showing up.

I used the edit to my custom BoardIndexTemplate.php as described above for my SMF v.1.0.5 forum.  The mod should work for the Default theme, but anything else will require modification to your BoardIndexTemplate.php for your version of SMF.

I am using the Default theme  :(

Is this in your 'boardindextemplate.php' file:

// "Users online Today"
        if(isset($context['num_users_today']))
        echo '
        <tr>
                <td class="catbg" colspan="2">', $txt['158bis'], ' ( ', $context['num_users_today'], ' ', $context['num_users_today'] == 1 ? $txt['user'] : $txt['users'], ' )</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center"><img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['158bis'], '" border="0" /></td>
                <td class="windowbg2" width="100%"><span class="smalltext">', $context['user_today'], '</span></td>
        </tr>';
Title: Re: Users Online Today Mod
Post by: California Dreamin on December 30, 2005, 01:04:33 AM
Quote from: RoarinRow on December 30, 2005, 12:46:19 AM
Quote from: fresnolady on December 30, 2005, 12:27:53 AM
Quote from: RoarinRow on December 29, 2005, 02:36:00 AM
Quote from: fresnolady on December 29, 2005, 02:28:02 AM
I have installed this and it is not showing up on my board. How do you activate it?
I have logged out and back in. Still not showing up.

I used the edit to my custom BoardIndexTemplate.php as described above for my SMF v.1.0.5 forum.  The mod should work for the Default theme, but anything else will require modification to your BoardIndexTemplate.php for your version of SMF.

I am using the Default theme  :(

Is this in your 'boardindextemplate.php' file:

// "Users online Today"
        if(isset($context['num_users_today']))
        echo '
        <tr>
                <td class="catbg" colspan="2">', $txt['158bis'], ' ( ', $context['num_users_today'], ' ', $context['num_users_today'] == 1 ? $txt['user'] : $txt['users'], ' )</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center"><img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['158bis'], '" border="0" /></td>
                <td class="windowbg2" width="100%"><span class="smalltext">', $context['user_today'], '</span></td>
        </tr>';


no, I don't see that......
Title: Re: Users Online Today Mod
Post by: HNHF on December 30, 2005, 02:41:49 AM
Hi There,

I am running  SMF RC2  and de Online Users Today mod won't work with this version.

Is there a update for it?

Greetings, Martin.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on December 30, 2005, 03:52:57 AM
I don't think so as the mod creator isn't a charter member, so they wouldn't be able to get rc2..
Title: Re: Users Online Today Mod
Post by: Carceri on December 30, 2005, 04:49:14 AM
There will be a version for RC2 as soon as I can get my hands on it :)
Title: Re: Users Online Today Mod
Post by: diegolyanky on December 31, 2005, 04:06:47 PM
It's working fine ... I instralled and modified files ...

But, :

How can I do to see the members what was online today in ALPHABETICALLY ORDER  ? It's that possible ?

I don't like to view in time logged order ...

Thanks and happy 2006  :D
Title: Re: Users Online Today Mod
Post by: Carceri on December 31, 2005, 11:03:01 PM
It's not possible to get them in alphabetically order with this mod, sorry.
Title: Re: Users Online Today Mod
Post by: SpyDie on January 02, 2006, 09:21:08 AM
Great mod!

I'm getting this quite alot in the forum error logs...

8: Undefined index: uot_yesterday
File: /home/landzdow/public_html/Sources/BoardIndex.php
Line: 366

Using RC2.

Line 366:

Quote$yesterday = $userday == $loginday ? '' : $txt['uot_yesterday'];

TIA
Title: Re: Users Online Today Mod
Post by: Carceri on January 02, 2006, 11:31:18 AM
It should be defined in "Modifications.english.php"
Title: Re: Users Online Today Mod
Post by: badja on January 03, 2006, 07:20:08 PM
HI all..
I am Downloaded this mod.
I have installed SMF 1.0.5

How can I Install This Mod?
Please Reply someone, How I can install it.. Step By Step..
I am an Newbie :S
Title: Re: Users Online Today Mod
Post by: Skipdawg on January 04, 2006, 01:49:53 AM
I put it on my test 1.1rc2 board and I love it. Using default theme.  ;)
Great job on this Mod. I now use it on 1.0.5, rc1 and rc2  ;D
Title: Re: Users Online Today Mod
Post by: beemer on January 04, 2006, 08:44:36 AM
Quote from: badja on January 03, 2006, 07:20:08 PM
HI all..
I am Downloaded this mod.
I have installed SMF 1.0.5

How can I Install This Mod?
Please Reply someone, How I can install it.. Step By Step..
I am an Newbie :S

Put the downloaded file in your packages folder, then go to packages in AdminCp and apply mod
Title: Re: Users Online Today Mod
Post by: Webster on January 05, 2006, 09:47:27 AM
My forum runs on 1.0.5 and this does not work, why?

The Paket Manager says installation ends with errors :(
Title: Re: Users Online Today Mod
Post by: SpyDie on January 05, 2006, 09:56:11 AM
Quote from: Webster on January 05, 2006, 09:47:27 AM
My forum runs on 1.0.5 and this does not work, why?

The Paket Manager says installation ends with errors :(

The Mod isn't supported on 1.0.5.
Title: Re: Users Online Today Mod
Post by: Webster on January 05, 2006, 10:26:05 AM
Quote from: SpyDie on January 05, 2006, 09:56:11 AM
Quote from: Webster on January 05, 2006, 09:47:27 AM
My forum runs on 1.0.5 and this does not work, why?

The Paket Manager says installation ends with errors :(

The Mod isn't supported on 1.0.5.

Is there another Who Was Online Mod which supports the 1.0.5?
Title: Re: Users Online Today Mod
Post by: RoarinRow on January 05, 2006, 01:21:58 PM
I got the v.1.0.5 version from this site - http://www.smitalia.net/community/index.php

It's called Online Users Today, instead of Users Online Today.
Title: Re: Users Online Today Mod
Post by: Webster on January 05, 2006, 04:28:52 PM
Quote from: RoarinRow on January 05, 2006, 01:21:58 PM
I got the v.1.0.5 version from this site - http://www.smitalia.net/community/index.php

It's called Online Users Today, instead of Users Online Today.
Thx! Work's fine :)
Title: Re: Users Online Today Mod
Post by: RoarinRow on January 05, 2006, 04:32:37 PM
Quote from: Webster on January 05, 2006, 04:28:52 PM
Quote from: RoarinRow on January 05, 2006, 01:21:58 PM
I got the v.1.0.5 version from this site - http://www.smitalia.net/community/index.php

It's called Online Users Today, instead of Users Online Today.
Thx! Work's fine :)

Welcome!  ;D
Title: Re: Users Online Today Mod
Post by: sistembusy on January 07, 2006, 02:25:31 PM
Quote from: RoarinRow on January 05, 2006, 04:32:37 PM
Quote from: Webster on January 05, 2006, 04:28:52 PM
Quote from: RoarinRow on January 05, 2006, 01:21:58 PM
I got the v.1.0.5 version from this site - http://www.smitalia.net/community/index.php

It's called Online Users Today, instead of Users Online Today.
Thx! Work's fine :)

Welcome!  ;D


Cool  ;D
God bless u all.. It works :)
Title: Re: Users Online Today Mod
Post by: dustrho on January 08, 2006, 06:37:38 PM
I was using this when I had SMF 1.0.5 installed, but due to a recent upgrade to 1.1 RC2 this isn't working anymore.  I later read that all mods should have been uninstalled prior to the upgrade, but I don't think that was CLEARLY communicated since so many people had problems with this last upgrade.  Well, this particular mod does not work anymore.

I am using the custom theme titled Dark Black Default.  I have tried uninstalling this mod and reinstalling it, and it still doesn't work.  The author of this particular theme said that I might have to edit some file or files in the Default theme, but I have no idea which file I'm supposed to be editing.  Any idea as to what needs editing or what I need to do in order to get this working?

If this has been asked before please point me in the right direction (instead of slamming me to the ground).  Thanks in advance!
Title: Re: Users Online Today Mod
Post by: Carceri on January 08, 2006, 08:05:41 PM
Just to make one thing clear, since it appears to cause some confusion: This mod has never been released for 1.0.5 and in fact does not work on 1.0.5. It works on 1.1 RC1 and 1.1 RC2 only.

There is apparently another mod which does more or less the same thing, which does work on 1.0.5. Please don't confuse those two.
Title: Re: Users Online Today Mod
Post by: dustrho on January 08, 2006, 09:11:27 PM
Quote from: Carceri on January 08, 2006, 08:05:41 PM
There is apparently another mod which does more or less the same thing, which does work on 1.0.5. Please don't confuse those two.

So how about telling us what this OTHER one you're referring to is called?  I could swear that the mod I'm referring to as being previously installed in my forum was Users Online Today.
Title: Re: Users Online Today Mod
Post by: RoarinRow on January 08, 2006, 09:24:26 PM
Quote from: dustrho on January 08, 2006, 09:11:27 PM
Quote from: Carceri on January 08, 2006, 08:05:41 PM
There is apparently another mod which does more or less the same thing, which does work on 1.0.5. Please don't confuse those two.

So how about telling us what this OTHER one you're referring to is called?  I could swear that the mod I'm referring to as being previously installed in my forum was Users Online Today.

For v.1.0.5 it is called, Online Users Today.
Title: Re: Users Online Today Mod
Post by: Gargoyle on January 08, 2006, 09:25:19 PM
I am getting an error when Installing on 1.1RC2....

3.     Execute Modification     ./Themes/default/BoardIndex.template.php     Test failed

Any suggestions ? I really like this MOD.. ;D
Title: Re: Users Online Today Mod
Post by: Carceri on January 09, 2006, 11:32:28 AM
Quote from: Gargoyle on January 08, 2006, 09:25:19 PM
I am getting an error when Installing on 1.1RC2....

3.     Execute Modification     ./Themes/default/BoardIndex.template.php     Test failed

Any suggestions ? I really like this MOD.. ;D
Are you using verion 1.3.1? 1.3.0 is for RC1 only?

Have you installed any other mods that modifies BoardIndex.template.php?

Are you sure that BoardIndex.template.php is an unmodified version from SMF 1.1 RC2?
Title: Re: Users Online Today Mod
Post by: Gobo on January 09, 2006, 05:33:24 PM
im getting the same error with install of this mod

i am using 1.1rc2 version of SMF

the mods I have installed are:

-Show Multiple Badges (Aka Stars)   1.0
-Quick Upload   2.1

Any help please?
Title: Re: Users Online Today Mod
Post by: Carceri on January 09, 2006, 06:06:37 PM
My guess is that one of these mods change ./Themes/default/BoardIndex.template.php so my mod no loger applies correctly. I suggest that you add this mod manually. There is another post in the beginning of this thread describing how to do this.
Title: Re: Users Online Today Mod
Post by: Gargoyle on January 09, 2006, 07:46:45 PM
I figured out what my problem was.... My BoardIndex file was modified but it was modified by me... Turns out my FTP program did not upload the SMF1.1RC2 version of the file correctly... Along with a few others...

So long story short the MOD is perfect ... My files were not... ;D
Title: Re: Users Online Today Mod
Post by: MrHeartbreaker on January 11, 2006, 05:05:58 AM
Hi friends
I just upgraded to 1.1 rc2 and want install Users Online Today Mod 1.3.1
After I finished download and applied it. Go the message like this.

Error in Package Installation

At least one error was encountered during a test installation of this package. It is strongly recommended that you do not continue with installation unless you know what you are doing, and have made a backup very recently. This error may be caused by a conflict between the package you're trying to install and another package you have already installed, an error in the package, a package which requires another package that you don't have installed yet, or a package designed for another version of SMF.

1. Execute Modification Users_Online_Today_Mod.xml Modification parse error
2. Execute Modification -                                               Modification parse error

I don't know how to do next.... can u pls help me to find out?
Thanks
Title: Re: Users Online Today Mod
Post by: Furvert on January 11, 2006, 11:46:15 PM
Online Users Today was by Fsan and all his mods were removed :(
It is possible he still has it available directly or via his sites.
That one was written for 1.0.5 and other versions
I had it working on 1.1b3p but lost it upgrading to rc2
It was very similar to this one, I do not know all the differences.

But one thing I may add later is to sort the list of users as this one doesn't do that.
Unless it sorts by last online?
I prefer alpha for this.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on January 12, 2006, 07:30:06 AM
yes, it sorts by last online
Title: Re: Users Online Today Mod
Post by: Carceri on January 13, 2006, 06:37:29 AM
Quote from: Furvert on January 11, 2006, 11:46:15 PM
But one thing I may add later is to sort the list of users as this one doesn't do that.
Unless it sorts by last online?
I prefer alpha for this.
As said it sorts by last online, and it will continue to do so :)

If you want to sort by username, just find

[$row['lastLogin'] . $row['memberName']]

and replace it with

[strtolower($row['memberName'])]

in BoardIndex.php. It occurs in two places.

In the same file, also change

krsort($context['users_online_today']);
krsort($context['list_users_online_today']);

to

ksort($context['users_online_today']);
ksort($context['list_users_online_today']);

This is just from memory and has not been tested at all.
Title: Re: Users Online Today Mod
Post by: HNHF on January 14, 2006, 02:26:35 AM
Hi There,

I have installed Online uses today mod for the SMF 1.1 RC2.

But i get still some errors.

Martin       Vandaag om 08:12:56

8: Undefined index: users_online
Bestand: f:\easyphp1-8\www\yabbsm\Themes\default\Stats.template.php (eval?)
Regel: 37

Can somebody help me with this...
Title: Re: Users Online Today Mod
Post by: on4ya on January 14, 2006, 03:21:48 AM
Hello Members.

I have installed Online Users Today 1.3.1  on SMF 1.1 RC2 and get alot of errors :

8: Undefined index: uot_user_online_today
Bestand: /home/beon4ya/public_html/vlaamsamateurradioforum/Themes/default/BoardIndex.template.php (main sub template - eval?)
Regel: 416

8: Undefined index: uot_users_online_today_title
Bestand: /home/beon4ya/public_html/vlaamsamateurradioforum/Themes/default/BoardIndex.template.php (main sub template - eval?)
Regel: 409

8: Undefined index: uot_users_online_today_title
Bestand: /home/beon4ya/public_html/vlaamsamateurradioforum/Themes/default/BoardIndex.template.php (main sub template - eval?)
Regel: 406

8: Undefined index: uot_yesterday
Bestand: /home/beon4ya/public_html/vlaamsamateurradioforum/Sources/BoardIndex.php
Regel: 368

Please , can someone help me with this.

Thanks.

Robert  8)
Title: Re: Users Online Today Mod
Post by: tolsta on January 14, 2006, 02:50:55 PM
Have a look at the Modifications.english.php file in the languages directory of the theme you are currently using and ensure it contains the following entries


$txt['uot_users_online_today_title']='Users Seen Today';
$txt['uot_user_online_today']='user seen today';
$txt['uot_users_online_today']='users seen today';
$txt['uot_total_users_online_today']='Users Seen Today';
$txt['uot_yesterday']='Yesterday at ';
Title: Re: Users Online Today Mod
Post by: Furvert on January 14, 2006, 03:56:37 PM
Thanks for the assist, I will see about changing the sort to alpha.
I use the list to check for certain people and its easier that way, the current sort is handy too so I may have to think about adding a switch. :D
Title: Re: Users Online Today Mod
Post by: on4ya on January 16, 2006, 02:11:40 AM
Quote from: tolsta on January 14, 2006, 02:50:55 PM
Have a look at the Modifications.english.php file in the languages directory of the theme you are currently using and ensure it contains the following entries


$txt['uot_users_online_today_title']='Users Seen Today';
$txt['uot_user_online_today']='user seen today';
$txt['uot_users_online_today']='users seen today';
$txt['uot_total_users_online_today']='Users Seen Today';
$txt['uot_yesterday']='Yesterday at ';


Hello Tolsta.

Thanks for the information.

I had to make these changes also in "Modifications.dutch.php"

Now everthing is working fine and no more errors.

Manny thanks.

Robert  8) :)
Title: Re: Users Online Today Mod
Post by: fiver on January 16, 2006, 05:00:40 PM
Thanks Carceri,

I installed on SMF1.1RC2 and it works instantly! Only as admin can I see the time. I tested as a normal member and I can't see the time. That's great. 8)

Its not shown as "Users Online Today" - its shown as "Users Seen Today"?

Does it also record if member browsed the forum as guest but not logged in, based on the ip address?

If not, perhaps it will be clearer if its "Users Logged In Today" or "Members Logged In Today" or just "Logged In Today".

;)
Title: Re: Users Online Today Mod
Post by: Carceri on January 16, 2006, 06:04:16 PM
All users should be able to see the time, unless the specific user has chosen to hide his online status. In that case, only the admin can see the last online time.

For RC2 the text has been renamed to "Users Seen Today". There were simply too many references to users online, so it got confusing. There already is an "Online Today". "Users Logged in Today", might be a good text also. I will consider this for 1.1 final, but please give me your suggestions here.

It does not handle guests, only users that actually log in.
Title: Re: Users Online Today Mod
Post by: fiver on January 16, 2006, 06:49:33 PM
I've changed it to "Logged In Today". :P
See: www.fivearts.net

The advantage is that you don't have to worry about using the wrong word "user" or "users".

Also, instead of

Logged In Today
[icon]  3 logged in today:
member1, member2, member3

... better to use

Logged In Today
[icon] Total: 3
member1, member2, member3

... or

Logged In Today: 3
[icon] member1, member2, member3

What do you think?

;)
Title: Re: Users Online Today Mod
Post by: fiver on January 16, 2006, 07:09:24 PM
Even less load if put it under

Users Online
0 Guests, 1 User
Users active in past 15 minutes:
member2
----------------- end tr ----------------
online.gifLogged In Today: 3
member1, member2, member3
----------------- end tr ----------------
Most Online Today: ... Most Online Ever: ...
----------------- end tr ----------------

Which means the 'td' for online.gif icon has to be changed from rowspan=2 to rowspan=3.

Notice the gradual increment in statistic:
- Past 15 minutes
- Logged In Today
- Most Online Today
- Most Online Ever

;)
Title: Re: Users Online Today Mod
Post by: Carceri on January 17, 2006, 02:19:23 AM
Actually I think I like the current layout better, but I will rethink this when 1.1 final is out :)
Title: Re: Users Online Today Mod
Post by: fiver on January 20, 2006, 12:21:55 PM
Hi Carceri,

I just found out that 1.1RC2's Most Online Today is only a highest recorded block of "Users active in past 15 minutes".
See 1.1.RC2 Most Online Today (http://www.simplemachines.org/community/index.php?topic=66800.0)

So I think your MOD has the right name for Users Online Today. thumbsup!

Is it possible to include number of Guests? Like this...

Users Online Today: 40 guests, 3 members
member1, member2, member3

I know this actually means out of the 40 guests, 10 of them has login. So better something like this...

Users Online Today: 40 guests, 3 had logged in.
member1, member2, member3

:)
Title: Re: Users Online Today Mod
Post by: Carceri on January 21, 2006, 06:16:16 AM
Quote from: fivearts on January 20, 2006, 12:21:55 PM
Is it possible to include number of Guests? Like this...

Not really, since there is no way to uniquely identify a quest. I mean I can't differentiate between a guest that visits the forum several times a day, and several guest visiting once a day.

One might use the IP addresses of the guests for an approximation, though.
Title: Re: Users Online Today Mod
Post by: kai920 on January 21, 2006, 06:21:47 AM
Hi,

Downloaded 1.3.1 from http://mods.simplemachines.org/index.php?mod=217

but the .zip seems to be corrupted? Can anyone confirm?
Title: Re: Users Online Today Mod
Post by: diegolyanky on January 21, 2006, 11:09:31 AM
Is not corrupted, try with Windows Extract or WinRar ...

Regards  ;)
Title: Re: Users Online Today Mod
Post by: kai920 on January 21, 2006, 11:40:22 AM
Quote from: diegolyanky on January 21, 2006, 11:09:31 AM
Is not corrupted, try with Windows Extract or WinRar ...

Regards  ;)

I'm using Winrar! and get "Unexepcted end of archive"  ::)
Title: Re: Users Online Today Mod
Post by: fiver on January 21, 2006, 12:25:08 PM
Sounds like download was terminated before it's 100% complete. Try redownload again?
Title: Re: Users Online Today Mod
Post by: fiver on January 21, 2006, 12:28:05 PM
Quote from: Carceri on January 21, 2006, 06:16:16 AM
Quote from: fivearts on January 20, 2006, 12:21:55 PM
Is it possible to include number of Guests? Like this...

Not really, since there is no way to uniquely identify a quest. I mean I can't differentiate between a guest that visits the forum several times a day, and several guest visiting once a day.

One might use the IP addresses of the guests for an approximation, though.

Thanks for the mod as it is. Hope someday that will be possible.  :D
Title: Re: Users Online Today Mod
Post by: diegolyanky on January 21, 2006, 01:31:17 PM
Quote from: kai920 on January 21, 2006, 11:40:22 AM
I'm using Winrar! and get "Unexepcted end of archive"  ::)

Download it again ... Is working fine.

Good Luck ...
Title: Re: Users Online Today Mod
Post by: mistermad on January 22, 2006, 10:30:22 AM
Good mod but I've been looking for something similar to what I had on my old phpBB board with the last vist mod installed, but couldn't find anything that matches that.

Then I stumbled upon this site when searching the web for it : http://www.puntingzone.com/forum/index.php and that's more or less what I'm looking for. Strangely I can't seem to find that on any other smf forum.

However I have no idea what mod that site uses or where I could find it? Any idea?

Or is there a way to develop the users online mod towards this?

Thanks for your help.

Title: Re: Users Online Today Mod
Post by: kai920 on January 22, 2006, 11:29:43 AM
That's an ... interesting site. :D  I see their implementation of the Today mod and wonder what it is as well.

What really interests me is their review directory script pzsearchform.php... has anyone heard of this or did they custom write it?
Title: Re: Users Online Today Mod
Post by: Carceri on January 22, 2006, 11:50:49 AM
Quote from: mistermad on January 22, 2006, 10:30:22 AM
Or is there a way to develop the users online mod towards this?

Sure there is. All it requires is someone with a little time to do it. It shouldn't be too difficult.
Title: Re: Users Online Today Mod
Post by: jerm on January 22, 2006, 03:19:44 PM
i know this has been discussed already, but i find it a tad annoying now.
The "Show others your online status?" is useless with this mod installed. A user can still see you browsing the forum. I know you will probably say that a user can just go into your profile and see when you last loged on, but thats not really the point. If i want to be hidden on my board, yet still view sections of the board that are restricted. I have to log in, and once i log in, it shows on the "users seen  today" list. Not showing the time doesn't really do anything, cause it updates as soon as you click a link and you move closer to the front of the list.

I enjoy the mod, and like seeing which users have been online during the day, but i can't hide from my users...
Title: Re: Users Online Today Mod
Post by: Carceri on January 23, 2006, 05:58:47 AM
I might change that in the future. For now, you can fix it yourself by adding the line


if (!allowedTo('moderate_forum') && empty($row['showOnline'])) continue;


Just below these lines


$context['users_online_today'] = array();
$context['list_users_online_today'] = array();

while ($row = mysql_fetch_assoc($result))
{


I still don't understand your comment "I know you will probably say that a user can just go into your profile and see when you last loged on, but thats not really the point".

What is the point then? You say you want to hide from your users, but you can't do that if they can just go into your profile and see when you were last online.
Title: Re: Users Online Today Mod
Post by: flapper on January 23, 2006, 06:08:58 AM
Cant seem to find the answer, how do you change the mod so that members are in alphabetical order, can be a pain with lots of members vising the site, to try and find out if they have visited the site today.

Thanks in advance.

:)
Title: Re: Users Online Today Mod
Post by: Prasad007 on January 23, 2006, 06:24:03 AM
Thanks for this mod! its gr8!!! :)
too bad it wont work on my non-default theme :(
Title: Re: Users Online Today Mod
Post by: Carceri on January 23, 2006, 06:27:04 AM
Quote from: flapper on January 23, 2006, 06:08:58 AM
Cant seem to find the answer, how do you change the mod so that members are in alphabetical order, can be a pain with lots of members vising the site, to try and find out if they have visited the site today.

Thanks in advance.

:)

http://www.simplemachines.org/community/index.php?topic=55513.msg452667#msg452667
Title: Re: Users Online Today Mod
Post by: flapper on January 23, 2006, 06:43:45 AM
Thanks, great mod
Title: Re: Users Online Today Mod
Post by: flapper on January 23, 2006, 11:47:18 AM
Ok Ive got the members in alphabetical order but half way it starts at a again. How do a put the members in alphabetical order from a to z without it doing it twice. Image unclosed
Title: Re: Users Online Today Mod
Post by: beemer on January 23, 2006, 01:48:29 PM
Quote from: Prasad007 on January 23, 2006, 06:24:03 AM

too bad it wont work on my non-default theme :(


Why not?
Title: Re: Users Online Today Mod
Post by: Carceri on January 23, 2006, 04:24:50 PM
Quote from: flapper on January 23, 2006, 11:47:18 AM
Ok Ive got the members in alphabetical order but half way it starts at a again. How do a put the members in alphabetical order from a to z without it doing it twice. Image unclosed
Don't know. As I said the code was untested. Apparently it doesn't work :)

Edit: Oh I just took a look at the picture :) It is working. When sorting alphabetically, capital letters come before lowercase letters. I have updated the previous post to not take uppercase letters into account.
Title: Re: Users Online Today Mod
Post by: kai920 on January 23, 2006, 11:42:26 PM
Installed 1.4.0 beta1... Just noticed one issue - I have a user logged in, his username is "D", and does NOT show up under "Users logged in today".

http://www.kaitech.hk/component/option,com_smf/Itemid,71/

edit#2 - just noticed another user not showing up under "Users logged in today"...  am I doing something wrong?
Title: Re: Users Online Today Mod
Post by: Carceri on January 24, 2006, 04:27:56 AM
Quote from: kai920 on January 23, 2006, 11:42:26 PM
Installed 1.4.0 beta1... Just noticed one issue - I have a user logged in, his username is "D", and does NOT show up under "Users logged in today".

http://www.kaitech.hk/component/option,com_smf/Itemid,71/

edit#2 - just noticed another user not showing up under "Users logged in today"...  am I doing something wrong?
Have the users not showing up chosen to hide their online status? If yes, are you the administrator and still can't see them when you are logged in?
Title: Re: Users Online Today Mod
Post by: kai920 on January 24, 2006, 04:34:13 AM
Found a 3rd user - just checked all 3 users profiles:

Show others your online status? was checked for all 3...

And I am the administrator - I saw them online under SMF's default "Who's Online" list, but their names do not appear in "Users Logged in Today". (1.4.0 beta 1)

edit : if you go to my site now, even as a guest you can see user "ninjaw" logged in, but he does not show up as having logged in TODAY.
Title: Re: Users Online Today Mod
Post by: kai920 on January 24, 2006, 05:01:10 AM
Hmm, strange - "ninjaw" is now shown as having logged in today, but I am still "missing" two users...
Title: Re: Users Online Today Mod
Post by: Carceri on January 24, 2006, 05:04:01 AM
Quote from: kai920 on January 24, 2006, 04:34:13 AM
And I am the administrator - I saw them online under SMF's default "Who's Online" list, but their names do not appear in "Users Logged in Today". (1.4.0 beta 1)
Can you confirm that this behaviour does not exist with version 1.3.1? Since a user suddenly appear, one might suspect something related to the time the user was logged in, but that code has not changed at all from 1.3.1...
Title: Re: Users Online Today Mod
Post by: kai920 on January 24, 2006, 05:12:32 AM
Quote from: Carceri on January 24, 2006, 05:04:01 AM
Quote from: kai920 on January 24, 2006, 04:34:13 AM
And I am the administrator - I saw them online under SMF's default "Who's Online" list, but their names do not appear in "Users Logged in Today". (1.4.0 beta 1)
Can you confirm that this behaviour does not exist with version 1.3.1? Since a user suddenly appear, one might suspect something related to the time the user was logged in, but that code has not changed at all from 1.3.1...

Sure, let me uninstall 1.4.0 and put back 1.3.1 and report back later...
Title: Re: Users Online Today Mod
Post by: Carceri on January 24, 2006, 05:19:10 AM
I just checked your member "D" and on his profile he is listed as being last active:

Yesterday at 08:26:10 PM

This time is what SMF stores in the database, and this is the time I read from the database to determine if a user was logged in today or not. If that time is incorrect, then clearly my mod does not work. If he was actually online earlier today, then I think you should report this as a bug in SMF
Title: Re: Users Online Today Mod
Post by: kai920 on January 24, 2006, 12:41:34 PM
You're absolutely right, I had no idea those times were reported wrong!

I suspect this may have something to do with the Joomla - SMF bridge?
Title: Re: Users Online Today Mod
Post by: Furvert on January 24, 2006, 05:54:45 PM
I decided to keep the list sorted by last active, it is quite useful. I may decide to add a selector for alpha or last active eventually.

I had already modified memberlist to add Last Login for those times I want to look up who logged in today. I also added age to memberlist since I have some content that needs it. So I decided I did not need the alpha sort so badly at the moment.

I wonder, is there a reasonable way to track how many bots have been on?
Or guests?
Likely IP is only way to count uniques but AOL will throw that off since it changes often. A user may have half a dozen IPs while loged in! Maybe worse.
Just curious, if IP is logged for guests then a Mod could do a lookup to seperate Users from Guests etc and show a count for Online Today.
Title: Re: Users Online Today Mod
Post by: MacGig on January 28, 2006, 09:52:37 AM
didnt work for me. I using the saf blue theme.
Title: Re: Users Online Today Mod
Post by: beemer on January 28, 2006, 04:10:55 PM
Quote from: macgeek on January 28, 2006, 09:52:37 AM
didnt work for me. I using the saf blue theme.

Did you make the manual changes to your saf blue theme?
Title: Re: Users Online Today Mod
Post by: desistyle on January 28, 2006, 07:39:14 PM
hi i just upgraded from smf 1.05 to smf 1.06 and the mod is not working can u guise please help
Title: Re: Users Online Today Mod
Post by: Carceri on January 28, 2006, 08:49:09 PM
The mod does not support 1.0.5 and will not support 1.0.6 either. It will support 1.1 final when it is available.
Title: Re: Users Online Today Mod
Post by: desistyle on January 28, 2006, 09:55:25 PM
well it used to work with smf 1.05 it used to show like how many users are online till now is it possible to get something like that for 1.06 please please
Title: Re: Users Online Today Mod
Post by: Carceri on January 29, 2006, 04:46:40 PM
Quote from: desistyle on January 28, 2006, 09:55:25 PM
well it used to work with smf 1.05

If it worked for 1.0.5 it was pure luck, as I have never tested it on 1.0.5. However, judging from some comments here, this mod does not work on 1.0.5. It will support 1.1 if you can wait until then :)
Title: Re: Users Online Today Mod
Post by: desistyle on January 29, 2006, 05:47:21 PM
ok sir will wait for your release thanks
Title: Re: Users Online Today Mod
Post by: diegolyanky on January 29, 2006, 08:20:01 PM
I don't like what the guests can see the users what was online today ... Be cause Google Spider is a GUEST and all members of my forum is appearing on google searcher  :o

The guests would not have to be able to see who was online.

What can I do ?
Title: Re: Users Online Today Mod
Post by: Carceri on January 30, 2006, 02:15:17 AM
Quote from: diegolyanky on January 29, 2006, 08:20:01 PM
The guests would not have to be able to see who was online.

What can I do ?

You can

1. Uninstall this mod
2. Modify it so guests cannot see who has been online today :)

But if your users are actually posting on your forum and guests can read those posts, Google will just pick up their names from there.

I will consider changing this behaviour in the next version, as I think that guests have no use for that information. If they are not part of the forum, they don't need to know who from the forum logged in today.
Title: Re: Users Online Today Mod
Post by: diegolyanky on January 30, 2006, 08:24:20 AM
Quote from: Carceri on January 30, 2006, 02:15:17 AM

You can

1. Uninstall this mod
2. Modify it so guests cannot see who has been online today :)


1° Uninstal this mod = NO ... Be cause I love this mod.
I just don't like what guests can see my users ( for competitors )
And Google Spider is registered as user, then Google YES can see all my forum.

2° I like to modify this mod, but I don't know how to do it  :(

Thanks for your reply .... And good job ( I repeat: " I love your mod " )

Title: Re: Users Online Today Mod
Post by: Owain on January 30, 2006, 09:26:15 AM
Installed the mod and it works a dream! Great Work!

One question, what file do I need to modify if I want to change the wording from "Users Seen Today" to something else...thanks.

Title: Re: Users Online Today Mod
Post by: Carceri on January 30, 2006, 02:00:32 PM
Quote from: Owain on January 30, 2006, 09:26:15 AM
One question, what file do I need to modify if I want to change the wording from "Users Seen Today" to something else...thanks.

Then you should edit 'Modifications.english.php'
Title: Re: Users Online Today Mod
Post by: Carceri on January 30, 2006, 02:42:43 PM
Quote from: diegolyanky on January 30, 2006, 08:24:20 AM
2° I like to modify this mod, but I don't know how to do it  :(
Try the 1.4.0 Beta 2 package I have just uploaded...
Title: Re: Users Online Today Mod
Post by: jerm on January 30, 2006, 11:43:33 PM
excellent. love the updates Carceri.
installed with no errors (1.4.0 beta 2)
Title: Re: Users Online Today Mod
Post by: ew1dm on January 31, 2006, 01:33:56 PM
... about this mod for SMF 1.05

Someone, whose nickname is "Fasan" has done (changed) this mod for SMF 1.05.
It worked perfect for 1.05. But it does not work with 1.06
Is there anyone (may be that "Fasan") who can do it again?
to good get accustomed quickly  :D
Title: Re: Users Online Today Mod
Post by: Carceri on January 31, 2006, 02:27:19 PM
Quote from: ew1dm on January 31, 2006, 01:33:56 PM
Someone, whose nickname is "Fasan" has done (changed) this mod for SMF 1.05.

Fasan did his own mod some time before I did this mod, but for reasons he has explained elsewhere in this thread, he removed it from these pages. I used a similar mod for phpBB and when searching for one for SMF I didn't find any and made my own. Since I was using 1.1 RC1 at that time, I never supported the 1.0.x versions and never will.

Hope this clears up some confusion.
Title: Re: Users Online Today Mod
Post by: desistyle on January 31, 2006, 02:35:43 PM
well i got a mod from this other site its workin with my smf 1.06 if u guise want i can post the link here and i think this is from fasan
Title: Re: Users Online Today Mod
Post by: fiver on February 01, 2006, 11:22:46 AM
Hi Carceri,

I have uninstalled the previous version and installed the new 1.4.0 Beta 2. It is perfect for members' privacy. Thanks.

One problem is after installation, my category table seems to have gone wrong. Please take a look.
http://www.fivearts.net/index.php#6

Any file that I can look to correct the error? Thanks.

* I also have "Googlebot & Spiders Mod" installed awhile ago.

Title: Re: Users Online Today Mod
Post by: Carceri on February 01, 2006, 03:55:09 PM
Quote from: fivearts on February 01, 2006, 11:22:46 AM
One problem is after installation, my category table seems to have gone wrong. Please take a look.
http://www.fivearts.net/index.php#6

Any file that I can look to correct the error? Thanks.

* I also have "Googlebot & Spiders Mod" installed awhile ago.

Yes, that looks strange. Don't know why, but I can't see how my mod touches this part. Take a look at BoardIndex.template.php. Perhaps uninstall my mod to see if the problem goes away. If yes, compare this file to itself before and after my mod is installed. See if it touches anything related to this.
Title: Re: Users Online Today Mod
Post by: fiver on February 02, 2006, 09:56:25 AM
Hi Carceri,

The problem seems to be the <acronym> tag filled into the subject and making it too long. As it happened the same time when I updated your mod, I mistaken it as being caused by it.  :P My apology. Thanks again for the fab Mod.  :D
Title: Re: Users Online Today Mod
Post by: fiver on February 11, 2006, 12:22:06 AM
Hi Carceri,

Just a note that when the homepage is loading, the alt text for the online.gif has a very long description:
alt="Users Online Users Logged In Today"

Which file should I find to change it to alt="Users Logged In Today"?

Thanks.  :D

Title: Re: Users Online Today Mod
Post by: Carceri on February 11, 2006, 05:57:14 AM
Quote from: fivearts on February 11, 2006, 12:22:06 AM
Hi Carceri,

Just a note that when the homepage is loading, the alt text for the online.gif has a very long description:
alt="Users Online Users Logged In Today"

Which file should I find to change it to alt="Users Logged In Today"?

You should change BoardIndex.template.php. I will also fix this in the next version.
Title: Re: Users Online Today Mod
Post by: Bigguy on February 13, 2006, 09:29:25 PM
How would I get the "Users Online Today Mod" to show up on the SMFOne_blue theme ??? WHat files need to be moddified ???
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on February 16, 2006, 01:20:18 PM
boardindex.template.php
Title: Re: Users Online Today Mod
Post by: Alan S on February 16, 2006, 04:24:09 PM
it dosent work for me at all??
Title: Re: Users Online Today Mod
Post by: Bigguy on February 16, 2006, 05:01:45 PM
K, thanks DemonicInfluence

Quote from: DemonicInfluence on February 16, 2006, 01:20:18 PM
boardindex.template.php
Title: Re: Users Online Today Mod
Post by: Carceri on February 17, 2006, 03:12:18 AM
Quote from: alan s on February 16, 2006, 04:24:09 PM
it dosent work for me at all??
Let me guess. You are not using the default theme?
Title: Re: Users Online Today Mod
Post by: perplexed on February 19, 2006, 11:09:11 AM
I love this mod, it makes the forum look so much healthier.

Usually all we see is the 'most online' which can be a little depressing, but now we see that there are a lot more people on the forum during a day, and its really great to know that many people are actually logging in every day.

Thanks!

I love this mod :)
Title: Re: Users Online Today Mod
Post by: p9939068 on February 20, 2006, 03:36:43 PM
Hi, i just installed it, but i dont see anything new on the Info Center. Yes i've switched to the default skin, but still it doesnt show. Is there some admin settings to this mod..?

by the way, i'm using 1.4.0 beta with rc2 :) this is my site: http://www.simdragons.com/smf/index.php

-edit- i checked through the .xml in the mod, and realised nothing in the "add" tag was added...none of the files listed in Users_Online_Today_Mod.xml was modified at all...weird

-edit2- the above prompted me to chmod all the listed files to 777, and voila, it works :P hope this will help any future users..
Title: Re: Users Online Today Mod
Post by: mcalan2001 on March 01, 2006, 08:28:13 AM
I can't get this mod to work.

It's very useful and I put it on every board I create.
However after upgrading a couple of boards from 1.1.b3 to 1.1.RC2 and re-installing the package, it goes through the motions with no error messages, but seems to have no effect.

I've looked through this topic and tried the suggestions, but with no luck.

I am using the default theme and have done a chmod 777 to all effected files.
Title: Re: Users Online Today Mod
Post by: Carceri on March 03, 2006, 03:23:40 AM
Quote from: mcalan2001 on March 01, 2006, 08:28:13 AM
I am using the default theme and have done a chmod 777 to all effected files.
Can you check the affected files, and see if any change has occurred to them? E.g. by comparing to the original files in SMF RC2.
Title: Re: Users Online Today Mod
Post by: tzd on March 03, 2006, 06:05:05 AM
What to edit in classic template to make this work?
Title: Re: Users Online Today Mod
Post by: cyberstang5.0 on March 07, 2006, 01:36:19 PM
I installed this mod on SMF 1.1rc2 and it works wonderful  :D

My question is, what can I do to restrict normal users from seeing this mod but only allow admins to see it?  Is there a way to incorporate permission to this mod?
Title: Re: Users Online Today Mod
Post by: Bigguy on March 07, 2006, 08:57:50 PM
No I dont believe there are permissions for this mod but there should be away to do that by modifying the code somehow. Its a good idea though. :)
Title: Re: Users Online Today Mod
Post by: cyberstang5.0 on March 07, 2006, 09:34:45 PM
Quote from: Bigguy on March 07, 2006, 08:57:50 PM
No I dont believe there are permissions for this mod but there should be away to do that by modifying the code somehow. Its a good idea though. :)
Alright, is there anyone brave enough to write the code for this?  I am not a programmer by any means...
Title: Re: Users Online Today Mod
Post by: Bigguy on March 07, 2006, 09:39:08 PM
I would help but I dont know enough about it yet, sorry.
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on March 08, 2006, 11:37:39 AM
just make it so that
if($context['user']['is_admin'])
{


is before the mod stuff in the boardindex.template.php of every theme.

Then at the end put
}

Should work to only allow admins to see..
Title: Re: Users Online Today Mod
Post by: Red on March 10, 2006, 07:43:03 AM
great mod...

any way to change the "online users" list so it would show the list in alphabetical order???
Title: Re: Users Online Today Mod
Post by: beemer on March 10, 2006, 01:51:21 PM
Quote from: Red on March 10, 2006, 07:43:03 AM
great mod...

any way to change the "online users" list so it would show the list in alphabetical order???


I am sure this has allready been covered in this post
Title: Re: Users Online Today Mod
Post by: cbrchris on April 04, 2006, 05:43:39 PM
Great mod!

It works with no problem under the defualt theme.  I am trying to modify the Helios Multi theme for it to work.

I know I have to modify the file: BoardIndex.template.php

I have attempted to insert the required code
// Users online today
echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


right before the line:
Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).'

when I attempt to save the updated file within the admin panel to modify the BoardIndex.template.php file, I get this error:   

The file you tried to save generated the following error:
Parse error: parse error, unexpected '>' in BoardIndex.template.php on line 445


line 445 of this file after the modification is:
<td class="windowbg" width="20" valign="middle" align="center">


The board is currently SMF 1.1 RC2.  Any assistance will be greatly appreciated. I don't know enough to determine what the problem is.

Thanks!
Title: Re: Users Online Today Mod
Post by: beemer on April 04, 2006, 06:30:34 PM
You dont want to put it there

find

                        Most users online today: '.$modSettings['mostOnlineToday'].' &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                        Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).'  )

                        </span>


                </td>
        </tr>';


And replace everything below with

// Users online today
echo '
<tr>
<td class="catbg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';

// If they are logged in, but SP1 style information is off... show a personal message bar.
if ($context['user']['is_logged'] && !$settings['show_sp1_info'])
{
echo '
<tr>
<td class="catbg" colspan="2">', $txt[159], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
', $context['allow_pm'] ? '<a href="' . $scripturl . '?action=pm">' : '', '<img src="', $settings['images_url'], '/message_sm.gif" alt="', $txt[159], '" border="0" />', $context['allow_pm'] ? '</a>' : '', '
</td>
<td class="windowbg2" valign="top">
<b><a href="', $scripturl, '?action=pm">', $txt[159], '</a></b>
<div class="smalltext">
', $txt[660], ' ', $context['user']['messages'], ' ', $context['user']['messages'] == 1 ? $txt[471] : $txt[153], '.... ', $txt[661], ' <a href="', $scripturl, '?action=pm">', $txt[662], '</a> ', $txt[663], '
</div>
</td>
</tr>';
}

// Show the login bar. (it's only true if they are logged out anyway.)
if ($context['show_login_bar'])
{
echo '
<tr>
<td class="catbg" colspan="2">', $txt[34], ' <a href="', $scripturl, '?action=reminder" class="smalltext">(' . $txt[315] . ')</a></td>
</tr>
<tr>
<td class="windowbg" width="20" align="center">
<a href="', $scripturl, '?action=login">
<img src="', $settings['images_url'], '/icons/login.gif" alt="', $txt[34], '" border="0" /></a>
</td>
<td class="windowbg2" valign="middle">
<form action="', $scripturl, '?action=login2" method="post" style="margin: 0;">
<table border="0" cellpadding="2" cellspacing="0" width="100%"><tr>
<td valign="middle" align="left">
<label for="user"><b>', $txt[35], ':</b><br /><input type="text" name="user" id="user" size="15" /></label>
</td>
<td valign="middle" align="left">
<label for="passwrd"><b>', $txt[36], ':</b><br /><input type="password" name="passwrd" id="passwrd" size="15" /></label>
</td>
<td valign="middle" align="left">
<label for="cookielength"><b>', $txt[497], ':</b><br /><input type="text" name="cookielength" id="cookielength" size="4" maxlength="4" value="', $modSettings['cookieTime'], '" /></label>
</td>
<td valign="middle" align="left">
<label for="cookieneverexp"><b>', $txt[508], ':</b><br /><input type="checkbox" name="cookieneverexp" id="cookieneverexp" checked="checked" class="check" /></label>
</td>
<td valign="middle" align="left">
<input type="submit" value="', $txt[34], '" />
</td>
</tr></table>
</form>
</td>
</tr>';
}


        echo '
</table></div>';
echo $botbox.'</div>';

}

?>
Title: Re: Users Online Today Mod
Post by: nebulous on April 05, 2006, 09:51:10 AM
great mod, thanks Carceri.

mouse over username showing last login time is not working in Opera, anyone facing the same problem?
work great on firefox though.

edit: sorry my fault, I disabled opera's "show tooltip"
Title: Re: Users Online Today Mod
Post by: cbrchris on April 05, 2006, 10:43:48 AM
Thanks beemer! That worked great.
Title: Re: Users Online Today Mod
Post by: beemer on April 05, 2006, 12:21:22 PM
Quote from: cbrchris on April 05, 2006, 10:43:48 AM
Thanks beemer! That worked great.

Glad to hear it  ;)
Title: Re: Users Online Today Mod
Post by: kcs on April 18, 2006, 10:14:37 PM
hi all,
i noticed that my MOST USERS stats is not updated... even after i "RECOUNT" under Forum maintenance...

any idea what went wrong?

thanks!
Title: Re: Users Online Today Mod
Post by: Backlash on April 19, 2006, 06:46:53 PM
i had a problem, and don't know how to fix it.


8: Undefined index: uot_hidden
Datei: /home/www/web23/html/board/Themes/default/BoardIndex.template.php (eval?)
Zeile: 419

8: Undefined index: uot_visible
Datei: /home/www/web23/html/board/Themes/default/BoardIndex.template.php (eval?)
Zeile: 419


8: Undefined index: uot_users_online_today_title
Datei: /home/www/web23/html/board/Themes/default/BoardIndex.template.php (eval?)
Zeile: 410


is there somebody who is able to help me??
Title: Re: Users Online Today Mod
Post by: perplexed on April 20, 2006, 08:13:45 AM
Quote from: kcs on April 18, 2006, 10:14:37 PM
hi all,
i noticed that my MOST USERS stats is not updated... even after i "RECOUNT" under Forum maintenance...

any idea what went wrong?

thanks!


I could be wrong but I thought that this mod shows the number of members online in a 24hour period, whereas your most users online is most members online at the one time?

So you could have 35 people online in a 24 hour period but only 10 of them on at the same time, so the most online would be 10 not 35

If that's wrong, someone let me know, but that was my understanding :)
Title: Re: Users Online Today Mod
Post by: perplexed on April 20, 2006, 08:18:00 AM
Quote from: Backlash on April 19, 2006, 06:46:53 PM
i had a problem, and don't know how to fix it.


8: Undefined index: uot_hidden
Datei: /home/www/web23/html/board/Themes/default/BoardIndex.template.php (eval?)
Zeile: 419

8: Undefined index: uot_visible
Datei: /home/www/web23/html/board/Themes/default/BoardIndex.template.php (eval?)
Zeile: 419


8: Undefined index: uot_users_online_today_title
Datei: /home/www/web23/html/board/Themes/default/BoardIndex.template.php (eval?)
Zeile: 410


is there somebody who is able to help me??

there is something about it here in this thread http://www.simplemachines.org/community/index.php?topic=36793.msg520999
Title: Re: Users Online Today Mod
Post by: kcs on April 21, 2006, 12:26:11 AM
hi,
agree with you on the "bottom" stats portion, but for the "top" portion, there's also a "Users seen today" value... and this value doesnt tally with the users seen on the main index page....

any idea what went wrong?

another query is that, how can i go about "adding" the MOST Seen online Users" on the bottom portion of the stats?

thanks!


Quote from: perplexed on April 20, 2006, 08:13:45 AM
I could be wrong but I thought that this mod shows the number of members online in a 24hour period, whereas your most users online is most members online at the one time?

So you could have 35 people online in a 24 hour period but only 10 of them on at the same time, so the most online would be 10 not 35

If that's wrong, someone let me know, but that was my understanding :)


Quote from: kcs on April 18, 2006, 10:14:37 PM
hi all,
i noticed that my MOST USERS stats is not updated... even after i "RECOUNT" under Forum maintenance...

any idea what went wrong?

thanks!


Title: Re: Users Online Today Mod
Post by: top_secret on April 23, 2006, 02:08:28 PM
hi people

i´m having problems with the installation...

apears to me this error:

-------------------------------------------------------------------------
391:                   </div>
392:                </td>
393:             </tr>
394:             <tr>
395:                <td class="windowbg2" width="100%">
396:                   <span class="middletext">
397:                      ', $txt['most_online_today'], ': <b>', $modSettings['mostOnlineToday'], '</b>.
398:                      // Users online today
399:    echo '

400:    <tr>

401:       <td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
402:    </tr><tr>
403:       <td class="windowbg" width="20" valign="middle" align="center">
404:          <img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />

----------------------------------------------------------------------------------------

Parse error: parse error, unexpected '>' in .../Themes/default/BoardIndex.template.php on line 400


please help me!!!

im using the DEFAULT THEME and the 1.1 RC2
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on April 23, 2006, 02:38:58 PM
Quote from: top_secret on April 23, 2006, 02:08:28 PM
hi people

i´m having problems with the installation...

apears to me this error:

-------------------------------------------------------------------------
391:                   </div>
392:                </td>
393:             </tr>
394:             <tr>
395:                <td class="windowbg2" width="100%">
396:                   <span class="middletext">
397:                      ', $txt['most_online_today'], ': <b>', $modSettings['mostOnlineToday'], '</b>.
398:                      // Users online today
399:    echo '

400:    <tr>

401:       <td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
402:    </tr><tr>
403:       <td class="windowbg" width="20" valign="middle" align="center">
404:          <img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />

----------------------------------------------------------------------------------------

Parse error: parse error, unexpected '>' in .../Themes/default/BoardIndex.template.php on line 400


please help me!!!

im using the DEFAULT THEME and the 1.1 RC2



Replace this:;


</div>
</td>
</tr>
<tr>
<td class="windowbg2" width="100%">
<span class="middletext">
', $txt['most_online_today'], ': <b>', $modSettings['mostOnlineToday'], '</b>.
// Users online today
echo '

<tr>

<td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />


with:

</div>
</td>
</tr>
<tr>
<td class="windowbg2" width="100%">
<span class="middletext">
', $txt['most_online_today'], ': <b>', $modSettings['mostOnlineToday'], '</b>.';
// Users online today
echo '

<tr>

<td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />

Title: Re: Users Online Today Mod
Post by: top_secret on April 23, 2006, 03:11:47 PM
now is this:

Quote419:    if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
420:       echo '<br />', implode(', ', $context['list_users_online_today']);
421:
422:    echo '
423:             <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
424:             <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
425:          </div>
426:       </td>
427:    </tr>';

428:                      ', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')

429:                   </span>
430:                </td>
431:             </tr>';

Parse error: parse error, unexpected T_STRING in .../Themes/default/BoardIndex.template.php on line 428

help please !!!  :'(
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on April 23, 2006, 04:55:12 PM
CHange this:

419:    if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
420:       echo '<br />', implode(', ', $context['list_users_online_today']);
421:
422:    echo '
423:             <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
424:             <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
425:          </div>
426:       </td>
427:    </tr>';

428:                      ', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')

429:                   </span>
430:                </td>
431:             </tr>';


to:

419:    if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
420:       echo '<br />', implode(', ', $context['list_users_online_today']);
421:
422:    echo '
423:             <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
424:             <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
425:          </div>
426:       </td>
427:    </tr>
428:                      ', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
429:                   </span>
430:                </td>
431:             </tr>';
Title: Re: Users Online Today Mod
Post by: top_secret on April 23, 2006, 05:18:06 PM
thanks BRO!!

works GREAT!!!


Regards  8)
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on April 23, 2006, 08:06:33 PM
No problem :)
Title: Re: Users Online Today Mod
Post by: WarBirD on April 29, 2006, 10:58:24 AM
Maybe a n00b question, but how can I use it for an other Theme than just the default ?

Wolfseye
Title: Re: Users Online Today Mod
Post by: WarBirD on April 29, 2006, 11:08:28 AM
Quote from: beemer on April 04, 2006, 06:30:34 PM
You dont want to put it there

find

                        Most users online today: '.$modSettings['mostOnlineToday'].' &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                        Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).'  )

                        </span>


                </td>
        </tr>';


And replace everything below with

// Users online today
echo '
<tr>
<td class="catbg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';

// If they are logged in, but SP1 style information is off... show a personal message bar.
if ($context['user']['is_logged'] && !$settings['show_sp1_info'])
{
echo '
<tr>
<td class="catbg" colspan="2">', $txt[159], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
', $context['allow_pm'] ? '<a href="' . $scripturl . '?action=pm">' : '', '<img src="', $settings['images_url'], '/message_sm.gif" alt="', $txt[159], '" border="0" />', $context['allow_pm'] ? '</a>' : '', '
</td>
<td class="windowbg2" valign="top">
<b><a href="', $scripturl, '?action=pm">', $txt[159], '</a></b>
<div class="smalltext">
', $txt[660], ' ', $context['user']['messages'], ' ', $context['user']['messages'] == 1 ? $txt[471] : $txt[153], '.... ', $txt[661], ' <a href="', $scripturl, '?action=pm">', $txt[662], '</a> ', $txt[663], '
</div>
</td>
</tr>';
}

// Show the login bar. (it's only true if they are logged out anyway.)
if ($context['show_login_bar'])
{
echo '
<tr>
<td class="catbg" colspan="2">', $txt[34], ' <a href="', $scripturl, '?action=reminder" class="smalltext">(' . $txt[315] . ')</a></td>
</tr>
<tr>
<td class="windowbg" width="20" align="center">
<a href="', $scripturl, '?action=login">
<img src="', $settings['images_url'], '/icons/login.gif" alt="', $txt[34], '" border="0" /></a>
</td>
<td class="windowbg2" valign="middle">
<form action="', $scripturl, '?action=login2" method="post" style="margin: 0;">
<table border="0" cellpadding="2" cellspacing="0" width="100%"><tr>
<td valign="middle" align="left">
<label for="user"><b>', $txt[35], ':</b><br /><input type="text" name="user" id="user" size="15" /></label>
</td>
<td valign="middle" align="left">
<label for="passwrd"><b>', $txt[36], ':</b><br /><input type="password" name="passwrd" id="passwrd" size="15" /></label>
</td>
<td valign="middle" align="left">
<label for="cookielength"><b>', $txt[497], ':</b><br /><input type="text" name="cookielength" id="cookielength" size="4" maxlength="4" value="', $modSettings['cookieTime'], '" /></label>
</td>
<td valign="middle" align="left">
<label for="cookieneverexp"><b>', $txt[508], ':</b><br /><input type="checkbox" name="cookieneverexp" id="cookieneverexp" checked="checked" class="check" /></label>
</td>
<td valign="middle" align="left">
<input type="submit" value="', $txt[34], '" />
</td>
</tr></table>
</form>
</td>
</tr>';
}


        echo '
</table></div>';
echo $botbox.'</div>';

}

?>


Ok, never mind, could change it with the Info in this Post in the Theme I wanted most and it works, but for the Blue Jeans Theme, I can´t find those lines, is it different in this Theme ?

Mfg

Wolfseye
Title: Re: Users Online Today Mod
Post by: perplexed on April 29, 2006, 01:39:16 PM
Quote from: kcs on April 21, 2006, 12:26:11 AM
hi,
agree with you on the "bottom" stats portion, but for the "top" portion, there's also a "Users seen today" value... and this value doesnt tally with the users seen on the main index page....

any idea what went wrong?

another query is that, how can i go about "adding" the MOST Seen online Users" on the bottom portion of the stats?

thanks!


Quote from: perplexed on April 20, 2006, 08:13:45 AM
I could be wrong but I thought that this mod shows the number of members online in a 24hour period, whereas your most users online is most members online at the one time?

So you could have 35 people online in a 24 hour period but only 10 of them on at the same time, so the most online would be 10 not 35

If that's wrong, someone let me know, but that was my understanding :)


Quote from: kcs on April 18, 2006, 10:14:37 PM
hi all,
i noticed that my MOST USERS stats is not updated... even after i "RECOUNT" under Forum maintenance...

any idea what went wrong?

thanks!




hmmm I see what you mean, that would be good.
Title: Re: Users Online Today Mod
Post by: iv_nik on April 29, 2006, 05:07:05 PM
Just read the whole topic and still have 2 questions:

Is it (or would it be) a possibility to modify initial period of time today logged users are shown in?
I mean what should I do, if I want have only last 12-hours logged in users, not 24h.

The 2nd question is how to hide usernames and left only total number of visitors.
Title: Re: Users Online Today Mod
Post by: Juggler on May 01, 2006, 10:11:32 AM
A bit confused here as I recently had to shift some files round to re-install a couple of mods and when I re-loaded this one I get an odd display (See description below). Any thoughts on what's gone wrong? (Just to note this is in all themes not just the default so I assume the problem is with either the boardindex or boardindex.template file).

There's no Users Online Today Header and this is the only info displayed so it looks like it's missing something!

: 13 (: 13, : 0)
Juggler, Muttley, Twinky, Tycho, bloodfalls, Getafix, Claud the crab, Nodders, whiteknuckle, OuzoIrene, Hong Kong Fooey, Ace, fwitt
Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 03, 2006, 05:07:41 AM
I am using SMF 1.1 RC 2 and i've installed Online Today Version 1.4.0 Beta 2.

From what i read, I need to modify BoardIndex.template.php to get it working in Helios Theme. Is the below code is the complete codes i need to edit ?

Quote from: beemer on April 04, 2006, 06:30:34 PM
You dont want to put it there

find

                        Most users online today: '.$modSettings['mostOnlineToday'].' &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                        Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).'  )

                        </span>


                </td>
        </tr>';


And replace everything below with

// Users online today
echo '
<tr>
<td class="catbg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';

// If they are logged in, but SP1 style information is off... show a personal message bar.
if ($context['user']['is_logged'] && !$settings['show_sp1_info'])
{
echo '
<tr>
<td class="catbg" colspan="2">', $txt[159], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
', $context['allow_pm'] ? '<a href="' . $scripturl . '?action=pm">' : '', '<img src="', $settings['images_url'], '/message_sm.gif" alt="', $txt[159], '" border="0" />', $context['allow_pm'] ? '</a>' : '', '
</td>
<td class="windowbg2" valign="top">
<b><a href="', $scripturl, '?action=pm">', $txt[159], '</a></b>
<div class="smalltext">
', $txt[660], ' ', $context['user']['messages'], ' ', $context['user']['messages'] == 1 ? $txt[471] : $txt[153], '.... ', $txt[661], ' <a href="', $scripturl, '?action=pm">', $txt[662], '</a> ', $txt[663], '
</div>
</td>
</tr>';
}

// Show the login bar. (it's only true if they are logged out anyway.)
if ($context['show_login_bar'])
{
echo '
<tr>
<td class="catbg" colspan="2">', $txt[34], ' <a href="', $scripturl, '?action=reminder" class="smalltext">(' . $txt[315] . ')</a></td>
</tr>
<tr>
<td class="windowbg" width="20" align="center">
<a href="', $scripturl, '?action=login">
<img src="', $settings['images_url'], '/icons/login.gif" alt="', $txt[34], '" border="0" /></a>
</td>
<td class="windowbg2" valign="middle">
<form action="', $scripturl, '?action=login2" method="post" style="margin: 0;">
<table border="0" cellpadding="2" cellspacing="0" width="100%"><tr>
<td valign="middle" align="left">
<label for="user"><b>', $txt[35], ':</b><br /><input type="text" name="user" id="user" size="15" /></label>
</td>
<td valign="middle" align="left">
<label for="passwrd"><b>', $txt[36], ':</b><br /><input type="password" name="passwrd" id="passwrd" size="15" /></label>
</td>
<td valign="middle" align="left">
<label for="cookielength"><b>', $txt[497], ':</b><br /><input type="text" name="cookielength" id="cookielength" size="4" maxlength="4" value="', $modSettings['cookieTime'], '" /></label>
</td>
<td valign="middle" align="left">
<label for="cookieneverexp"><b>', $txt[508], ':</b><br /><input type="checkbox" name="cookieneverexp" id="cookieneverexp" checked="checked" class="check" /></label>
</td>
<td valign="middle" align="left">
<input type="submit" value="', $txt[34], '" />
</td>
</tr></table>
</form>
</td>
</tr>';
}


        echo '
</table></div>';
echo $botbox.'</div>';

}

?>

Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 03, 2006, 03:25:17 PM
Followed beemer instruction and manage to get the function working but i dont think it is the latest version of this mod. I did read the "Users_Online_Today_Mod" file and follow the instruction but after a few trial. I still couldn't get it working.

Below is the printscreen of what i've got after follow beemer instruction.

(http://img428.imageshack.us/img428/7821/useron6te.jpg) (http://imageshack.us)
Title: Re: Users Online Today Mod
Post by: Juggler on May 03, 2006, 06:20:57 PM
(http://bluebuzzards.com/uotimage.jpg)

Well it's more than what I have and this is on a clean install! Something hasn't gone into the file but I can't find what's missing.
Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 03, 2006, 09:38:33 PM
Juggler, which version of the Users Online Today Mod did you install ?
Title: Re: Users Online Today Mod
Post by: Juggler on May 04, 2006, 10:47:04 AM
1.4 Beta 2
Title: Re: Users Online Today Mod
Post by: WarBirD on May 05, 2006, 06:37:59 AM
In this Theme, called MERCURY (http://themes.simplemachines.org/index.php?lemma=18), I can´t find any of this whats to replace. All that stuff is just not in there in the BoardIndex.Template.php.

What now ?
Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 05, 2006, 06:49:25 AM
Quote from: WarBirD on May 05, 2006, 06:37:59 AM
In this Theme, called MERCURY (http://themes.simplemachines.org/index.php?lemma=18), I can´t find any of this whats to replace. All that stuff is just not in there in the BoardIndex.Template.php.

What now ?

The source code in different theme is different if i am not mistaken. I manage to get it working perfectly on my default theme & Themis but as for Helios Theme below is the result.

(http://img428.imageshack.us/img428/7821/useron6te.jpg)

Did make a backup for my BoardIndex.Template but wrongly replace it already. So, i've no more backup file for my original Helios BoardIndex.Template :(
Title: Re: Users Online Today Mod
Post by: WarBirD on May 05, 2006, 06:56:46 AM
Well, so I don´t think I will get it to work in the MERCURY Theme, when its so different. I am not so a php / html freak, i got some things to work, but not when I can´t find any hint how to do it. In this case, it seems, i reached one of those points. :(
Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 05, 2006, 06:57:24 AM
This is the screenshot of the edit i made in default theme & themis theme

(http://img73.imageshack.us/img73/4104/defth7rm.jpg) (http://imageshack.us)

(http://img67.imageshack.us/img67/9378/themthe9qt.jpg) (http://imageshack.us)

As for Helios one i can't get it working by following the file instruction but manage to get it working by following beemer instruction but i guess the instruction is an earlier version coz there is no

- Total
- ( Visible , Hidden )

So, anyone here know how to fix this ?
Title: Re: Users Online Today Mod
Post by: L.G.S on May 05, 2006, 11:12:32 AM
Hey Vinspire, is there any chance you could should me the part where you added the whos online code under please?
Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 05, 2006, 11:15:26 AM
Quote from: L.G.S on May 05, 2006, 11:12:32 AM
Hey Vinspire, is there any chance you could should me the part where you added the whos online code under please?

Modify BoardIndex.template.php and follow the instruction below

Quote from: beemer on April 04, 2006, 06:30:34 PM
You dont want to put it there

find

                        Most users online today: '.$modSettings['mostOnlineToday'].' &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                        Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).'  )

                        </span>


                </td>
        </tr>';


And replace everything below with

// Users online today
echo '
<tr>
<td class="catbg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';

// If they are logged in, but SP1 style information is off... show a personal message bar.
if ($context['user']['is_logged'] && !$settings['show_sp1_info'])
{
echo '
<tr>
<td class="catbg" colspan="2">', $txt[159], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
', $context['allow_pm'] ? '<a href="' . $scripturl . '?action=pm">' : '', '<img src="', $settings['images_url'], '/message_sm.gif" alt="', $txt[159], '" border="0" />', $context['allow_pm'] ? '</a>' : '', '
</td>
<td class="windowbg2" valign="top">
<b><a href="', $scripturl, '?action=pm">', $txt[159], '</a></b>
<div class="smalltext">
', $txt[660], ' ', $context['user']['messages'], ' ', $context['user']['messages'] == 1 ? $txt[471] : $txt[153], '.... ', $txt[661], ' <a href="', $scripturl, '?action=pm">', $txt[662], '</a> ', $txt[663], '
</div>
</td>
</tr>';
}

// Show the login bar. (it's only true if they are logged out anyway.)
if ($context['show_login_bar'])
{
echo '
<tr>
<td class="catbg" colspan="2">', $txt[34], ' <a href="', $scripturl, '?action=reminder" class="smalltext">(' . $txt[315] . ')</a></td>
</tr>
<tr>
<td class="windowbg" width="20" align="center">
<a href="', $scripturl, '?action=login">
<img src="', $settings['images_url'], '/icons/login.gif" alt="', $txt[34], '" border="0" /></a>
</td>
<td class="windowbg2" valign="middle">
<form action="', $scripturl, '?action=login2" method="post" style="margin: 0;">
<table border="0" cellpadding="2" cellspacing="0" width="100%"><tr>
<td valign="middle" align="left">
<label for="user"><b>', $txt[35], ':</b><br /><input type="text" name="user" id="user" size="15" /></label>
</td>
<td valign="middle" align="left">
<label for="passwrd"><b>', $txt[36], ':</b><br /><input type="password" name="passwrd" id="passwrd" size="15" /></label>
</td>
<td valign="middle" align="left">
<label for="cookielength"><b>', $txt[497], ':</b><br /><input type="text" name="cookielength" id="cookielength" size="4" maxlength="4" value="', $modSettings['cookieTime'], '" /></label>
</td>
<td valign="middle" align="left">
<label for="cookieneverexp"><b>', $txt[508], ':</b><br /><input type="checkbox" name="cookieneverexp" id="cookieneverexp" checked="checked" class="check" /></label>
</td>
<td valign="middle" align="left">
<input type="submit" value="', $txt[34], '" />
</td>
</tr></table>
</form>
</td>
</tr>';
}


        echo '
</table></div>';
echo $botbox.'</div>';

}

?>

Title: Re: Users Online Today Mod
Post by: L.G.S on May 05, 2006, 05:39:28 PM
Damn nevermind, I do not have that code.

I got this error

314: // Users online today
315:    echo '

THIS LINE WRONG >>316:    <tr>

317:       <td class="catbg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
318:    </tr><tr>
319:       <td class="windowbg" width="20" valign="middle" align="center">
Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 05, 2006, 10:07:52 PM
No idea L.G.S :P
Title: Re: Users Online Today Mod
Post by: Juggler on May 07, 2006, 06:29:04 AM
OK, found my problem. For some reason it had not added the txt strings to the Modifications English file. Stuck them in and all is well with the world.
Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 07, 2006, 11:29:42 AM
Glad to hear that Juggler  :D :D :D
Title: Re: Users Online Today Mod
Post by: DVD_GR on May 07, 2006, 02:59:32 PM
seeking for 1.07 version,does something exist???
Title: Re: Users Online Today Mod
Post by: Bigguy on May 07, 2006, 03:08:24 PM
No I don`t believe it is compatible with 1.0.7

http://mods.simplemachines.org/index.php?mod=217
Title: Re: Users Online Today Mod
Post by: geezmo on May 08, 2006, 02:56:10 AM
I'm using Default Theme, SMF ver. 1.1RC2. Successfully installed this without any prob, but the list does not appear in the info Center. Do I need to activate this somewhere or edit some templates to make this work?
Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 08, 2006, 05:23:52 AM
What list doesn't appear in info center ?
Title: Re: Users Online Today Mod
Post by: geezmo on May 08, 2006, 05:44:14 AM
The Online Users Today list. That's supposed to appear below the "Users Online" list right, as in your post in Post #295 of this thread? Or do I still need to edit some template?
Title: Re: Users Online Today Mod
Post by: Vinspire^ on May 08, 2006, 07:54:19 AM
Quote from: geezmo on May 08, 2006, 05:44:14 AM
The Online Users Today list. That's supposed to appear below the "Users Online" list right, as in your post in Post #295 of this thread? Or do I still need to edit some template?

I thought you said the mod had been installed successfully ?
Title: Re: Users Online Today Mod
Post by: Bigguy on May 08, 2006, 09:12:14 AM
If you have a custom theme you will have to edit template files.
Title: Re: Users Online Today Mod
Post by: geezmo on May 08, 2006, 07:40:14 PM
I have the Default theme. The mod was supposedly successfully installed but all I see in the Info Center is this:

QuoteUsers Online
Users Online    x Guests, x Users
Users active in past 15 minutes:
xxxxxx
[More Stats]
Most Online Today: x. Most Online Ever: x (May x, 2006, xx:xx PM)

Shouldn't I have another line for Users Logged In Today like in HERE (http://www.simplemachines.org/community/index.php?topic=55513.msg568756#msg568756)?

Title: Re: Users Online Today Mod
Post by: scottws on May 08, 2006, 10:44:50 PM
I have the exact same behavior as geezmo:

Title: Re: Users Online Today Mod
Post by: scottws on May 08, 2006, 11:02:56 PM
Turns out it was a permission issue.

I tried uninstalling the mod, and every test failed.  It then said I didn't have permissions in the Packages directory, or one of its files.  The permissions on Packages was 777, so I don't know how that can be.

I ended up nuking the forum and installing a backup.  Then I chmodded the entire forum to 777 and it installed and displayed ok.

Edit: Well, not wanting my whole forum with all directories and files set with permissions of 777, I wiped out the whole forum and restored a recent backup.

The thing is, I can't figure out why it's not working.  Every file and directory is owned by user "smf" and group "forum," and that's the user/group combination I'm using to install/uninstall.  I did look at the owner of the files again, and some were "www-data."  I ran a chown -R smf.forum *.

Then I tried installing the mod again, this time without the crazy all 777 permissions.  I experienced the same behavior as before:  it claimed to install just fine, but it wasn't there and it won't uninstall. When I attempt to uninstall it, I get the following message:

QuoteYou cannot download or install new packages because the Packages directory or one of the files in it are not writable!

Well, the Packages folder is owned by smf.forum, and has 777 permissions set.  Inside, the backups folder is also 777. installed.list, smf_patch-1.0.7-1.1RC2-1.tar.gz, and Users_Online_Today_1.4.0_beta_2.zip have 666 permissions.  index.php is the only thing that does not have write permissions.  It's permissions are 644.

So I don't know what it is talking about since the requisite files have the proper write permissions.

I followed this guide to set permissions: http://www.activewebhosting.com/faq/scripts-simplemachines.html

So basically all permissions are the standard 755 for directories and 644 for files, except:


Is there some better guide on how to set file and folder permissions so packages installed via the package manager actually work?  I was going to try to install the package manually, but all that it contains are two XML files which seem to sort of work automatically.
Title: Re: Users Online Today Mod
Post by: Bigguy on May 08, 2006, 11:46:23 PM
Is the backup folder inside the packages folder also chmodded to 777
Title: Re: Users Online Today Mod
Post by: scottws on May 09, 2006, 06:34:50 AM
Quote from: Bigguy on May 08, 2006, 11:46:23 PM
Is the backup folder inside the packages folder also chmodded to 777

Yes:

Quote from: scottws on May 08, 2006, 11:02:56 PMWell, the Packages folder is owned by smf.forum, and has 777 permissions set.  Inside, the backups folder is also 777.
Title: Re: Users Online Today Mod
Post by: scottws on May 09, 2006, 02:32:07 PM
I changed my ownership on all files and directories to www-data.www-data, which is what Apache2 runs as.  This solved my problem.
Title: Re: Users Online Today Mod
Post by: geezmo on May 09, 2006, 02:40:56 PM
So it's now working on your forum, scott? You installed then uninstalled then changed permissions then installed the mod again?
Title: Re: Users Online Today Mod
Post by: scottws on May 09, 2006, 03:29:56 PM
I have a recent backup of the forum, so I kept testing the installation and uninstallation.  When it broke or failed, I just nuked the whole forum and restored the backup.

The only ways I was able to get it to work were to chmod the whole forum to 777 or to chown to www-data.www-data (previously was owned by smf.forum). Following the guides I saw for setting certain folder and file permissions to 777 and 666 and then using the user "smf" FTP login information in the package manager did not work.
Title: Re: Users Online Today Mod
Post by: scottws on May 09, 2006, 03:35:00 PM
Hmm...

It correctly works on the default theme:

(http://eac.forgiven5.com/pictures/usersonline.png)

But following beemer's instructions to get this mod working on Helios resulted in the same thing Vinspire^ is experiencing:

(http://eac.forgiven5.com/pictures/usersonline_helios.png)
Title: Re: Users Online Today Mod
Post by: Viceroy on May 10, 2006, 07:52:52 AM
Are there any plans to make this mod available for 1.0.7 by any chance?
Title: Re: Users Online Today Mod
Post by: geezmo on May 10, 2006, 08:19:35 AM
at least, scott, something's showing in your forum. in mine (Default Theme, 1.1RC2), the mod was supposedly successfully installed but nothing appears.
Title: Re: Users Online Today Mod
Post by: scottws on May 10, 2006, 08:43:07 AM
Quote from: geezmo on May 10, 2006, 08:19:35 AM
at least, scott, something's showing in your forum. in mine (Default Theme, 1.1RC2), the mod was supposedly successfully installed but nothing appears.
Yeah, like I previously posted, I was having the same problem.

For me, it was an issue with permissions.  I was never able to nail down exactly which files and/or directories it was failing on since I got around it by giving read, write, and execute permissions to everyone, and then later making the owner and group of the files and directories the user Apache runs under.

But I have shell and root access to mess around with that sort of thing with ease: it's my server.
Title: Re: Users Online Today Mod
Post by: Stuart on May 10, 2006, 08:52:51 AM
Quote from: Viceroy on May 10, 2006, 07:52:52 AM
Are there any plans to make this mod available for 1.0.7 by any chance?

You can read my last post which you can find HERE (http://www.simplemachines.org/community/index.php?topic=55513.msg433857#msg433857) :D

As the file in that message isn't working anymore you can get if from my server HERE (http://www.astmaforum.nl/downloads/OnLineUserToday_13_10.zip)  ;D
Title: Re: Users Online Today Mod
Post by: geezmo on May 10, 2006, 09:01:21 AM
scott, I have VPS and I can basically do the same. But I don't think it's worth it given the fact that this mod is supposedly released and thus should be working perfectly. We need to find what's wrong with the mod so it will be a good, working mod for SMF.
Title: Re: Users Online Today Mod
Post by: L.G.S on May 10, 2006, 01:12:39 PM
Can I ever get some help for my problem please?
Title: Re: Users Online Today Mod
Post by: scottws on May 10, 2006, 01:28:12 PM
Quote from: L.G.S on May 10, 2006, 01:12:39 PM
Can I ever get some help for my problem please?
When you installed the package, did it say it was installed successfully and pass all tests?  If so, did it actually appear at the bottom of the board index of the default Core theme?

If not, your problem was in the installation of the mod in the first place.  I believe the code beemer provided was to get this mod to work in the Helios theme as well (after intalling it via the package manager for the default theme).

It sounds like you replaced the wrong portion of code, cut out too much, left too much, or just don't have a proper installation of the mod in the first place.

I would start by restoring a backup of the Default.template.php file, if you have one.
Title: Re: Users Online Today Mod
Post by: L.G.S on May 10, 2006, 01:51:46 PM
The default installation went fine, I know how to see if it did or not.

Want I want to know is how to install it on my theme - Aqua Slate
Title: Re: Users Online Today Mod
Post by: scottws on May 10, 2006, 02:48:27 PM
For someone looking for help, you sure do cop an attitude.
Title: Re: Users Online Today Mod
Post by: L.G.S on May 10, 2006, 04:50:28 PM
You may perceive it as an attitude, but it wasn't posted with one so I'm sorry if you took it that way.
Title: Re: Users Online Today Mod
Post by: cyberstang5.0 on May 10, 2006, 09:45:24 PM
Quote from: DemonicInfluence on March 08, 2006, 11:37:39 AM
just make it so that
if($context['user']['is_admin'])
{


is before the mod stuff in the boardindex.template.php of every theme.

Then at the end put
}

Should work to only allow admins to see..

Another stupid programing question for ya'll...

How do I get it so admins and moderators (or specific membergroups) see the list but keep it "hidden" from regular users?  ???
Title: Re: Users Online Today Mod
Post by: Vinspire on May 10, 2006, 11:38:59 PM
Quote from: scottws on May 09, 2006, 03:35:00 PM
Hmm...

It correctly works on the default theme:

(http://eac.forgiven5.com/pictures/usersonline.png)

But following beemer's instructions to get this mod working on Helios resulted in the same thing Vinspire^ is experiencing:

(http://eac.forgiven5.com/pictures/usersonline_helios.png)

Scot, did you manage to get a solution for this ? If so kindly instruct me about it on how to solve it. Thanks :)
Title: Re: Users Online Today Mod
Post by: scottws on May 10, 2006, 11:42:57 PM
Nope. No solution as of yet. I have to look at the code.
Title: Re: Users Online Today Mod
Post by: Vinspire on May 10, 2006, 11:54:59 PM
Quote from: scottws on May 10, 2006, 11:42:57 PM
Nope. No solution as of yet. I have to look at the code.

The code that beemer gave and the code we are using in default theme with clean installation is different code.

I tried using the new code but it came out with an error. So, i am currently using beemer guide.
Title: Re: Users Online Today Mod
Post by: DVD_GR on May 11, 2006, 10:25:35 PM
From where can we download older versions who are compatible with 1.07??
Latest says its only for 1.1 rc2?So it doesnt work on 1.07??  ::)
Title: Re: Users Online Today Mod
Post by: Gobo on May 11, 2006, 11:47:05 PM
For users of 1.1RC2

I have a hell of a lot of themes installed on my forum and the easiest way to modify the boardindex.template.php file is to simply look for this line:

// If they are logged in, but SP1 style information is off... show a personal message bar.

it occurs in all the themes --- just place the code above it

it works A-OK
Title: Re: Users Online Today Mod
Post by: Carceri on May 12, 2006, 07:37:50 AM
Quote from: DVD_GR on May 11, 2006, 10:25:35 PM
From where can we download older versions who are compatible with 1.07??
Latest says its only for 1.1 rc2?So it doesnt work on 1.07??  ::)

I know I have said this before, but since this thread is rather long, I guess most people haven't read all of it. Therefore I will say it again.

There is no version for the 1.0 series from me, for the simple reason that I have never used the 1.0 series.

There is one for 1.1 RC1 and RC2, and there will be one for RC3 and 1.1 Final when they eventually are done.
Title: Re: Users Online Today Mod
Post by: scottws on May 14, 2006, 09:40:50 AM
Quote from: akulion on May 11, 2006, 11:47:05 PM
For users of 1.1RC2

I have a hell of a lot of themes installed on my forum and the easiest way to modify the boardindex.template.php file is to simply look for this line:

// If they are logged in, but SP1 style information is off... show a personal message bar.

it occurs in all the themes --- just place the code above it

it works A-OK
"Just place the code..."  What code are you referring to?  Beemer's code?
Title: Re: Users Online Today Mod
Post by: L.G.S on May 14, 2006, 11:52:25 AM
Quote from: akulion on May 11, 2006, 11:47:05 PM
For users of 1.1RC2

I have a hell of a lot of themes installed on my forum and the easiest way to modify the boardindex.template.php file is to simply look for this line:

// If they are logged in, but SP1 style information is off... show a personal message bar.

it occurs in all the themes --- just place the code above it

it works A-OK

Woah it worked, thanks a hellava bunch mate!
Title: Re: Users Online Today Mod
Post by: Gobo on May 15, 2006, 01:05:45 PM
Quote from: scottws on May 14, 2006, 09:40:50 AM
Quote from: akulion on May 11, 2006, 11:47:05 PM
For users of 1.1RC2

I have a hell of a lot of themes installed on my forum and the easiest way to modify the boardindex.template.php file is to simply look for this line:

// If they are logged in, but SP1 style information is off... show a personal message bar.

it occurs in all the themes --- just place the code above it

it works A-OK
"Just place the code..."  What code are you referring to?  Beemer's code?

The code I am referring to is this:




// Users online today
echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';






Important Always remember to make a back-up of your original file before any modifications are made - that way EVEN if something goes wrong you dont have to worry because you can upload the old file and everything will be back to normal :)

Title: Re: Users Online Today Mod
Post by: Gobo on May 15, 2006, 04:19:30 PM
Quote
(http://eac.forgiven5.com/pictures/usersonline_helios.png)

Users with this problem follow these instructions:

1. Go to your theme folder for the theme in which u are having this problem

2. Go to the Languages folder and download this file Modifications.english.php

3. Make a backup of this file in case u mess up

4. Open the file in a text editor and just before the ?> right at the end of the file, add the following code



$txt['uot_users_online_today_title']='Users Seen Today';
$txt['uot_user_online_today']='user seen today';
$txt['uot_users_online_today']='users seen today';
$txt['uot_total_users_online_today']='Users Seen Today';
$txt['uot_yesterday']='Yesterday at ';



4. save and upload
Title: Re: Users Online Today Mod
Post by: wallis77 on May 15, 2006, 10:24:48 PM
i use blackTed Skin and have 1.1rc2 this is all great it works on the other skins but not on the one i currently use for my forum, sorry if this has been discussed already on the previous 20+ pages but how can i get it to work on my current skin?
Title: Re: Users Online Today Mod
Post by: scottws on May 16, 2006, 09:00:31 AM
Quote from: akulion on May 15, 2006, 04:19:30 PM

Users with this problem follow these instructions:

1. Go to your theme folder for the theme in which u are having this problem

2. Go to the Languages folder and download this file Modifications.english.php

3. Make a backup of this file in case u mess up

4. Open the file in a text editor and just before the ?> right at the end of the file, add the following code



$txt['uot_users_online_today_title']='Users Seen Today';
$txt['uot_user_online_today']='user seen today';
$txt['uot_users_online_today']='users seen today';
$txt['uot_total_users_online_today']='Users Seen Today';
$txt['uot_yesterday']='Yesterday at ';



4. save and upload

I am not seeing a Modifications.english.php file in Themes/helios_multi11rc2/languages/.
Title: Re: Users Online Today Mod
Post by: SpyDie on May 16, 2006, 12:45:42 PM
Quote from: akulion on May 15, 2006, 04:19:30 PM
I am not seeing a Modifications.english.php file in Themes/helios_multi11rc2/languages/.

In which case, go and open a New Notepad window on your own system.

Copy & paste the contents of this box into it. Save it as Modifications.english.php, upload it to Themes/helios_multi11rc2/languages/.

Quote<?php

$txt['uot_users_online_today_title']='Users Seen Today';
$txt['uot_user_online_today']='user seen today';
$txt['uot_users_online_today']='users seen today';
$txt['uot_total_users_online_today']='Users Seen Today';
$txt['uot_yesterday']='Yesterday at ';

?>

Works perfectly on my own forum, I have mutliple themes - I placed this into every single theme folder and it worked perfectly.

HTH
Title: Re: Users Online Today Mod
Post by: scottws on May 16, 2006, 02:09:21 PM
I was going to try that, but I wasn't sure it would make a difference.

I've been told not to edit PHP files with Notepad.  I use vim directly on the server.
Title: Re: Users Online Today Mod
Post by: scottws on May 16, 2006, 02:25:13 PM
Ok, SpyDie's modifications seemed to work, but I was wondering if there was a way to make it more like how it appears on the default theme:

QuoteTotal: 2 (Visible: 2, Hidden: 0)

instead of how it is now after doing the modification:

Quote2 users seen today

Edit: It looks like it has something to do with this in beemer's code for BoardIndex.template.php:

echo $context['num_users_online_today'], ' ', $context['num_users_online_today']
      == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];


It looks like that is showing a number (the number of users that were online), then testing if that number is equal to one or not, and then using one of two variables depending on the result.

So I could probably move that around and then change the value of the variables in Modifications.english.php to reflect what appears in the default theme for this mod.  The problem comes in that I don't know PHP very well at all, so I don't want to break the line of code by trying to move stuff around.
Title: Re: Users Online Today Mod
Post by: Vinspire on May 17, 2006, 05:27:39 AM
Follow akulion guide but i still couldn't get it working. Anyone manage to get it working ?
Title: Re: Users Online Today Mod
Post by: Carceri on May 17, 2006, 05:49:27 AM
Quote from: scottws on May 16, 2006, 02:25:13 PM
QuoteTotal: 2 (Visible: 2, Hidden: 0)

instead of how it is now after doing the modification:

Quote2 users seen today
This was changed from the second to the first in a later version of the mod. Probably the code you are trying to use is based on an old version of this mod.
Title: Re: Users Online Today Mod
Post by: Vinspire on May 17, 2006, 06:04:34 AM
Quote from: Carceri on May 17, 2006, 05:49:27 AM
Quote from: scottws on May 16, 2006, 02:25:13 PM
QuoteTotal: 2 (Visible: 2, Hidden: 0)

instead of how it is now after doing the modification:

Quote2 users seen today
This was changed from the second to the first in a later version of the mod. Probably the code you are trying to use is based on an old version of this mod.

Carceri, yep. That is what i suspect too that beemer code is from the old version but when i tried it with the new codes ... it gaves me an error.
Title: Re: Users Online Today Mod
Post by: Gobo on May 17, 2006, 07:44:12 AM
Quote from: Vinspire on May 17, 2006, 05:27:39 AM
Follow akulion guide but i still couldn't get it working. Anyone manage to get it working ?

Please note the following Error I made in posting the last code (I have fixed it in my last post as well but posting here just so that everyone knows)

The boardindex.template.php file must be modified as following: (for helios theme)

Download you boardindex.template.php file is to simply look for this line:

// If they are logged in, but SP1 style information is off... show a personal message bar.

it occurs in all the themes --- just place the following code above it





// Users online today
echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';





That should fix it :)

Important Always remember to make a back-up of your original file before any modifications are made - that way EVEN if something goes wrong you dont have to worry because you can upload the old file and everything will be back to normal :)



================================================================
==============Below are steps ONLY for people who have already modified the file using my past instructions====================================================

Simply find this in your boardindex.template.php file and REMOVE it



', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';
]]></search>
<add><![CDATA[




this was the part I had accidentally included in the code from the mod package - what it simply does is search and replace a bit of code - so removing it should fix any sort of errors :) A good way to search for the above code would be to simply do a search for <add><![CDATA[

find it - compare the 2 bits of code in your file and the one given here and remove it :)
Title: Re: Users Online Today Mod
Post by: scottws on May 17, 2006, 08:37:09 AM
Quote from: Carceri on May 17, 2006, 05:49:27 AM
Quote from: scottws on May 16, 2006, 02:25:13 PM
QuoteTotal: 2 (Visible: 2, Hidden: 0)

instead of how it is now after doing the modification:

Quote2 users seen today
This was changed from the second to the first in a later version of the mod. Probably the code you are trying to use is based on an old version of this mod.

Ok, well then does anyone have any idea how to get this properly working on the Helios theme?
Title: Re: Users Online Today Mod
Post by: Vinspire on May 17, 2006, 11:01:54 AM
Quote from: scottws on May 17, 2006, 08:37:09 AM
Quote from: Carceri on May 17, 2006, 05:49:27 AM
Quote from: scottws on May 16, 2006, 02:25:13 PM
QuoteTotal: 2 (Visible: 2, Hidden: 0)

instead of how it is now after doing the modification:

Quote2 users seen today
This was changed from the second to the first in a later version of the mod. Probably the code you are trying to use is based on an old version of this mod.

Ok, well then does anyone have any idea how to get this properly working on the Helios theme?

Scott, I am looking for the same answer as well. Did you tried akulion codes ? I did tried but it gaves me an error. Guess i did something wrong with the codes. :( :( :(
Title: Re: Users Online Today Mod
Post by: rsj1 on May 17, 2006, 04:51:00 PM
Is there a way to make this hack (I'm using 1.4 beta) with the default skin show users online in the last 24 hours (IE keep cycling around instead of resetting at midnight)? Any help or suggestions would be most appreciated ;)
Title: Re: Users Online Today Mod
Post by: Carceri on May 18, 2006, 07:20:56 AM
Quote from: rsj1 on May 17, 2006, 04:51:00 PM
Is there a way to make this hack (I'm using 1.4 beta) with the default skin show users online in the last 24 hours (IE keep cycling around instead of resetting at midnight)? Any help or suggestions would be most appreciated ;)

That should be easy. In BoardIndex.php find


$nowdate = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);


And replace with


$midnight = time() - 86400;


And in Stats.php find


$frag = explode('-', strftime('%Y-%m-%d', time()));
$midnight = forum_time(false, mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]));


and replace with


$midnight = time() - 86400;


Also edit Modifications.english.php to the appropriate text you want displayed
Title: Re: Users Online Today Mod
Post by: rsj1 on May 20, 2006, 11:02:56 AM
 ;D Many thanks it worked a treat!

Quote from: Carceri on May 18, 2006, 07:20:56 AM
Quote from: rsj1 on May 17, 2006, 04:51:00 PM
Is there a way to make this hack (I'm using 1.4 beta) with the default skin show users online in the last 24 hours (IE keep cycling around instead of resetting at midnight)? Any help or suggestions would be most appreciated ;)

That should be easy. In BoardIndex.php find


$nowdate = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);


And replace with


$midnight = time() - 86400;


And in Stats.php find


$frag = explode('-', strftime('%Y-%m-%d', time()));
$midnight = forum_time(false, mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]));


and replace with


$midnight = time() - 86400;


Also edit Modifications.english.php to the appropriate text you want displayed
Title: Re: Users Online Today Mod
Post by: kriskd on May 21, 2006, 11:14:05 AM
Quote from: akulion on May 15, 2006, 04:19:30 PM
Quote
(http://eac.forgiven5.com/pictures/usersonline_helios.png)

Users with this problem follow these instructions:

1. Go to your theme folder for the theme in which u are having this problem

2. Go to the Languages folder and download this file Modifications.english.php

3. Make a backup of this file in case u mess up

4. Open the file in a text editor and just before the ?> right at the end of the file, add the following code



$txt['uot_users_online_today_title']='Users Seen Today';
$txt['uot_user_online_today']='user seen today';
$txt['uot_users_online_today']='users seen today';
$txt['uot_total_users_online_today']='Users Seen Today';
$txt['uot_yesterday']='Yesterday at ';



4. save and upload
Quote from: akulion on May 17, 2006, 07:44:12 AM
Please note the following Error I made in posting the last code (I have fixed it in my last post as well but posting here just so that everyone knows)

The boardindex.template.php file must be modified as following: (for helios theme)

Download you boardindex.template.php file is to simply look for this line:

// If they are logged in, but SP1 style information is off... show a personal message bar.

it occurs in all the themes --- just place the following code above it





// Users online today
echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';





That should fix it :)

Important Always remember to make a back-up of your original file before any modifications are made - that way EVEN if something goes wrong you dont have to worry because you can upload the old file and everything will be back to normal :)

I have done both these steps.  First on my test forum and I got it working beautifully.  Then, I went to duplicate it on my real forum and for whatever reason I can't get it to work.  Here is what is displayed:

Attachment deleted

Does this give anyone a clue as to what I did wrong?
Title: Re: Users Online Today Mod
Post by: kriskd on May 21, 2006, 11:40:41 AM
Okay, never mind on my users online today.  I got it working, but now my SMF shoutbox isn't working.  I'll try that thread now....
Title: Re: Users Online Today Mod
Post by: cyberstang5.0 on June 02, 2006, 11:27:19 AM
Quote from: cyberstang5.0 on May 10, 2006, 09:45:24 PM
Quote from: DemonicInfluence on March 08, 2006, 11:37:39 AM
just make it so that
if($context['user']['is_admin'])
{


is before the mod stuff in the boardindex.template.php of every theme.

Then at the end put
}

Should work to only allow admins to see..

Another stupid programing question for ya'll...

How do I get it so admins and moderators (or specific membergroups) see the list but keep it "hidden" from regular users?  ???
Anyone?  ??? ??? :(
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on June 03, 2006, 09:27:42 AM
That is how to keep hidden from other users other than admin...

For moderators try only allowing the moderator group?
Title: Re: Users Online Today Mod
Post by: cotdagoo on June 03, 2006, 11:52:38 AM
using the latest version of the mod, and 1.1rc2 of SMF - I'm having banned users showing up on the users online today list.. is it possible to have this removed? I keep getting questions from my members about banned poeple accessing the forum.

any help is appreciated.
Title: Re: Users Online Today Mod
Post by: Bigguy on June 03, 2006, 11:53:43 AM
You might see them online but I think all there viewing is a "You are banned" message.
Title: Re: Users Online Today Mod
Post by: cotdagoo on June 03, 2006, 03:05:44 PM
Quote from: Bigguy on June 03, 2006, 11:53:43 AM
You might see them online but I think all there viewing is a "You are banned" message.

Indeed.. however it's still somewhat confusing to regular members who don't have access to viewing error logs to see that it's just a ban message. I've litterally gotten about 10-15 PMs from people asking why banned names still show up (just in the past 2 days)

Is there not any way to filter banned users out of the list, much like the hidden users are? Seems kinda silly to include users that are banned in the list.. perhaps that's just my personal prefrence though.

cheers
Title: Re: Users Online Today Mod
Post by: Carceri on June 03, 2006, 06:46:15 PM
Quote from: cotdagoo on June 03, 2006, 03:05:44 PM
Is there not any way to filter banned users out of the list, much like the hidden users are? Seems kinda silly to include users that are banned in the list.. perhaps that's just my personal prefrence though.

I guess it's a personal preference. You might argue that they are active on the forum that day, even though they are banned. You can also argue that they are not valid users because they have been banned. Both points are valid IMO.
Title: Re: Users Online Today Mod
Post by: ghostfreak on June 04, 2006, 03:46:09 PM
Great mod, works fine :)
Title: Re: Users Online Today Mod
Post by: tzd on June 05, 2006, 05:17:45 PM
What do i have to edit in my croatian language to make this work?
Title: Re: Users Online Today Mod
Post by: WarBirD on June 06, 2006, 02:18:20 AM
I tried all that stuff and never got it to work  :(, I need it for the black22 (http://themes.simplemachines.org/index.php?lemma=19) Theme. Anyone can help me with that ?

WarBirD
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on June 08, 2006, 03:11:26 PM
MANUALLY EDIT the boardindex.template.php in your black22 theme..
Title: Re: Users Online Today Mod
Post by: WarBirD on June 08, 2006, 03:54:58 PM
Yeah, tried that, it ended this way.

Quote
Template Parse Error!
There was a problem loading the /Themes/black22_11rc2/BoardIndex.template.php template or language file. Please check the syntax and try again - remember, single quotes (') often have to be escaped with a slash (\). To see more specific error information from PHP, try accessing the file directly.

You may want to try to refresh this page or use the default theme.

Parse error: parse error, unexpected T_STRING in .../Themes/black22_11rc2/BoardIndex.template.php on line 435

426:
427:         echo '
428:                                 <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
429:                                 <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
430:                         </span>
431:                 </td>
432:         </tr>';
433:
434:

435:                      ', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')

436:                   </span>
437:                </td>
438:             </tr>';
439: ]]></search>

I did it with the Code that was written at page 23 of this Thread.

Quote from: akulion on May 15, 2006, 01:05:45 PM
Quote from: scottws on May 14, 2006, 09:40:50 AM
Quote from: akulion on May 11, 2006, 11:47:05 PM
For users of 1.1RC2

I have a hell of a lot of themes installed on my forum and the easiest way to modify the boardindex.template.php file is to simply look for this line:

// If they are logged in, but SP1 style information is off... show a personal message bar.

it occurs in all the themes --- just place the code above it

it works A-OK
"Just place the code..."  What code are you referring to?  Beemer's code?

The code I am referring to is this:




', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';
]]></search>
<add><![CDATA[
// Users online today
echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';





Important Always remember to make a back-up of your original file before any modifications are made - that way EVEN if something goes wrong you dont have to worry because you can upload the old file and everything will be back to normal :)


Title: Re: Users Online Today Mod
Post by: perplexed on June 10, 2006, 10:34:31 AM
Quote from: cotdagoo on June 03, 2006, 03:05:44 PM
Quote from: Bigguy on June 03, 2006, 11:53:43 AM
You might see them online but I think all there viewing is a "You are banned" message.

Indeed.. however it's still somewhat confusing to regular members who don't have access to viewing error logs to see that it's just a ban message. I've litterally gotten about 10-15 PMs from people asking why banned names still show up (just in the past 2 days)

Is there not any way to filter banned users out of the list, much like the hidden users are? Seems kinda silly to include users that are banned in the list.. perhaps that's just my personal prefrence though.

cheers
you could always ban users from your entire .com via cpanel :)
Title: Re: Users Online Today Mod
Post by: perplexed on June 10, 2006, 10:45:10 AM
I'm not sure where we are with this but can someone explain this to me:


Users Online
Users Online    0 Guests, 1 User
Users active in past 15 minutes:
Perplexed
Most Online Today: 15. Most Online Ever: 85 (December 20, 2005, 05:43:09 AM)


Users Seen Today <----- the users online today mod
Users Online Users Seen Today    
26 users seen today:
*names removed*

If 26 users were seen today then why does it show most online today as 15. 

This is confusing
Title: Re: Users Online Today Mod
Post by: cotdagoo on June 10, 2006, 09:01:29 PM
@perplexed - yes.. I have resorted to banning the static IP from cpanel, but when a user changes their IP, it just creates more work.

regarding the users online today thing.. the "Most online today" refers the most people online at one time (default is within 15min) - so you had 26 users log in throughout the day, but 15 was the number of users online at the same time.
Title: Re: Users Online Today Mod
Post by: tinhyeuon on June 11, 2006, 02:00:35 PM
sorry!
I want hack it into my forum 1.0.7.
SO can i hack it ok?
Title: Re: Users Online Today Mod
Post by: Carceri on June 12, 2006, 05:47:11 AM
Quote from: tinhyeuon on June 11, 2006, 02:00:35 PM
sorry!
I want hack it into my forum 1.0.7.
SO can i hack it ok?

That depends on your skills :) I am sure it isn't too difficult to make it work with 1.0.7, but it doesn't out of the box
Title: Re: Users Online Today Mod
Post by: L.G.S on June 18, 2006, 06:34:03 AM
Sorry if this has been asked, but how do I let the mod show for guests instead of just the number of people who came on?
Title: Re: Users Online Today Mod
Post by: tapirul on June 18, 2006, 01:18:09 PM
regarding seeing users that are hidden on the "users online today," I don't think the problem is totally solved by changing the italics and not-showing-the-time-on-hover. It's very easy to figure out "who is the user that is hidden and connected right now". Let me tell you how:
- you see on "users online", say, "3 users online, (1 hidden)"
- on the list "users online today", the first three users shown are exactly the users online at the moment. Well, you just saw who's the "hidden" one (those unhidden appear on both list).
My point is that, by showing all users "online today" (includding those hidden), this mod actually cancels user's choice to post hidden.
It's a great mod though, and I wouldn't want to quit it. Is there any way to fix it by showing, to regular users, ONLY the users that are not hidden (on the "users onlyne today" list)? OR, another way would be to randomize the list on "online today" so the users connected at a moment do not appear first on the list. Alphabetic order maybe? In this case it would be impossible to do the trick I described.

PS sorry if the issue has been discussed further, I've read this topic only 'till page 5 or so - lack of free time...

It would be, also, wonderful if there were some settings in the admin panel you could control (turning int on or of for example, or giving permissions to see the list to specific groups). I understand that this takes a lot of codind, I am just dreaming :)
Title: Re: Users Online Today Mod
Post by: Carceri on June 19, 2006, 03:23:02 AM
Quote from: tapirul on June 18, 2006, 01:18:09 PM
My point is that, by showing all users "online today" (includding those hidden), this mod actually cancels user's choice to post hidden.

The behaviour you want, is exactly how 1.4.0 Beta 2 handles things. Hidden users are not shown on the list to regular users, only admins.
Title: Re: Users Online Today Mod
Post by: Carceri on June 19, 2006, 04:05:56 AM
Quote from: L.G.S on June 18, 2006, 06:34:03 AM
Sorry if this has been asked, but how do I let the mod show for guests instead of just the number of people who came on?

You modify the source code :) Look in BoardIndex.template.php for $context['user']['is_guest']. It occurs twice in the file.

I would really like to add a control panel at some point where you could change some options, since it is impossible to satisfy everyone this the same set of options. The problem is, as you all know, the lack of time.
Title: Re: Users Online Today Mod
Post by: tapirul on June 19, 2006, 11:11:46 AM
thanks ceceri. I am still using 1.3.0 (afraid of betas..:))...
Anyway, I found a way around the issue I mentioned above. All credits go to Ştefan Tălpălaru, actually.
To show Users online today in alphabetical order rather than login time, you have to do some minor modifications in the BoardIndex.php file (Sources folder), as follows:
Delete "$row['lastLogin'] . " from here

$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
'id' => $row['ID_MEMBER'],
'username' => $row['memberName'],
'name' => $row['realName'],
'group' => $row['ID_GROUP'],
'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
'link' => $link,
'is_buddy' => $is_buddy,
'hidden' => empty($row['showOnline']),
);

$context['list_users_online_today'][$row['lastLogin'] . $row['memberName']] = (empty($row['showOnline']) && allowedTo('moderate_forum')) ? '<i>' . $link . '</i>' : $link;


so it will look like

$context['users_online_today'][$row['memberName']] = array(
'id' => $row['ID_MEMBER'],
'username' => $row['memberName'],
'name' => $row['realName'],
'group' => $row['ID_GROUP'],
'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
'link' => $link,
'is_buddy' => $is_buddy,
'hidden' => empty($row['showOnline']),
);

$context['list_users_online_today'][$row['memberName']] = (empty($row['showOnline']) && allowedTo('moderate_forum')) ? '<i>' . $link . '</i>' : $link;


and change "krsort" with "ksort"
  mysql_free_result($result);

   krsort($context['users_online_today']);
   krsort($context['list_users_online_today']);


Remeber, in ASCII capital letters come before small letters (I didn't know..), so all usernames starting with a capital letter will come first.
This works great if  you want your users to be able to see who was online today (regardless hidden/unhidden), without figuring out who's online at the moment

Title: Re: Users Online Today Mod
Post by: Carceri on June 19, 2006, 01:03:54 PM
Quote from: tapirul on June 19, 2006, 11:11:46 AM
thanks ceceri. I am still using 1.3.0 (afraid of betas..:))...
Anyway, I found a way around the issue I mentioned above. All credits go to Ştefan Tălpălaru, actually.

Well, I posted a similar solution somewhere in this thread when someone wanted the list sorted by usernames instead of last logged in :)

By the way... I actually think that 1.4.0 beta 2 has less bugs than 1.3.0 as it has been around for a long time without any problems. It would have been called 1.4.0 final when SMF 1.1 was released as final, but that seems to take a long time.
Title: Re: Users Online Today Mod
Post by: tapirul on June 19, 2006, 01:47:54 PM
 :)
I didn't have the patience to read 25 pages.. :P
Is there any way I can upgrade to 1.4, or I have to uninstall first?
Title: Re: Users Online Today Mod
Post by: Carceri on June 20, 2006, 02:11:30 AM
You need to uninstall the old version first. Somewhere in these 26 pages are descriptions of bad things that can happen if you just install it op top of an old version :)
Title: Re: Users Online Today Mod
Post by: tapirul on June 20, 2006, 11:18:27 AM
okay, i'l read an uninstall
Title: Re: Users Online Today Mod
Post by: TGB on June 20, 2006, 08:18:12 PM
This is not a huge problem but im just wondering how to fix it.

I have successfully installed the mod onto my custom theme
the only problem is that it is using this border: (http://www.dreamcasthaven.com/forum/Themes/TechBlue1/images/catbg2.gif)

and i think it is supposed to be this border: (http://www.dreamcasthaven.com/forum/Themes/TechBlue1/images/catbg.gif)

See here:
(http://freespaces.com/acidbath/tech_blue.png)

The default theme seems to be working fine:
(http://freespaces.com/acidbath/default.png)


I've tried several things and still can't manage to fix it.
Title: Re: Users Online Today Mod
Post by: RoarinRow on June 21, 2006, 12:55:05 AM
I have multiple themes on my site and this is what I did to my BoardIndex.template.php file:

Find this:

// Users online today

   echo '
   <tr>
      <td class="titlebg" colspan="2">'

Change the "titlebg" to "catbg"

Be sure to backup your file.
Title: Re: Users Online Today Mod
Post by: auroramae on June 21, 2006, 08:38:05 AM
regarding showing guests-
Quote from: Carceri on June 19, 2006, 04:05:56 AM
You modify the source code :) Look in BoardIndex.template.php for $context['user']['is_guest']. It occurs twice in the file.

I have the same question but I am clueless as to how to change this to make the guests show as users in the list.  A member asked that we show them as we are a community site and we get many more guests than members on the boards.

I am hoping you can find the time to walk me through how I should change it?

I posted the question in the general coding section and I couldn't delete it...sorry for the redundant post.

BTW  I love this mod!
aurora
SMF 1.1 RC2
Title: Re: Users Online Today Mod
Post by: TGB on June 21, 2006, 01:45:58 PM
Quote from: RoarinRow on June 21, 2006, 12:55:05 AM
I have multiple themes on my site and this is what I did to my BoardIndex.template.php file:

Find this:

// Users online today

   echo '
   <tr>
      <td class="titlebg" colspan="2">'

Change the "titlebg" to "catbg"

Be sure to backup your file.

Works perfectly thanks
Title: Re: Users Online Today Mod
Post by: RoarinRow on June 21, 2006, 01:51:55 PM
Quote from: edsloter on June 21, 2006, 01:45:58 PM
Quote from: RoarinRow on June 21, 2006, 12:55:05 AM
I have multiple themes on my site and this is what I did to my BoardIndex.template.php file:

Find this:

// Users online today

   echo '
   <tr>
      <td class="titlebg" colspan="2">'

Change the "titlebg" to "catbg"

Be sure to backup your file.

Works perfectly thanks

Welcome, glad to help.  8)
Title: Re: Users Online Today Mod
Post by: Carceri on June 22, 2006, 09:05:09 AM
Quote from: auroramae on June 21, 2006, 08:38:05 AM
I have the same question but I am clueless as to how to change this to make the guests show as users in the list.

This is not what my previous post referred to. It was how to show the list of online users to guest visiting the forum, not to show the guests in the list. IMO showing guests in the list 1) doesn't make much sense, and 2) is actually impossible to do as discussed previously in this thread.

1) You will end up with a list with a lot of entries saying "Guest". That's hardly useful information :)

2) You cannot distinguish a guest from a previous guest that has visited the forum earlier that day.
Title: Re: Users Online Today Mod
Post by: auroramae on June 22, 2006, 11:01:52 AM
Sorry for mistaking one issue for another.

I realize that it is impossible to distinguish guests.
I did read the previous thread regarding the issues you cite.

Would it be possible to show the total number of guests?
Or is that shown somewhere else in the stats that I am not seeing?
Even if it was not accurate it would give a rough idea of how many people browsed the board that day.

aurora
Title: Re: Users Online Today Mod
Post by: Carceri on June 23, 2006, 06:45:26 PM
Quote from: auroramae on June 22, 2006, 11:01:52 AM
I realize that it is impossible to distinguish guests.
<snip>
Would it be possible to show the total number of guests?

I guess you answered your own question :)

One could do a rough estimate of the number of times a guest user visited the forum, or the number of different ip addresses used by guests, but as far as I know that information is not available in the database, so one would have to add it first.
Title: Re: Users Online Today Mod
Post by: auroramae on June 23, 2006, 10:26:29 PM
Thanks for taking the time to reply to my elementary quieries!
Title: Re: Users Online Today Mod
Post by: carola0102 on June 25, 2006, 06:50:11 AM
I'm using chatbubbles theme.. how to make this mod visible after installing it? Should I edit only the BoardIndex.template.php? And what exactly should I edit? I read the guidelines on this forum. But still I couldnt make it :-[ Can anyone please help?

Thanks in advance,
Carola
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on June 26, 2006, 07:02:19 PM
only edit boardindex.template.php
Title: Re: Users Online Today Mod
Post by: Fatih! on June 28, 2006, 06:53:31 AM
I want to list user online last 24 hour.
How can i do this?

Thanx
Title: Re: Users Online Today Mod
Post by: PrizeLive.com on June 28, 2006, 10:13:33 AM
Installed successfully!! Thanks..

You can find it here: http://www.moneytalkpro.com/index.php if you want to see it :D.

Quote from: DeDu on June 28, 2006, 06:53:31 AM
I want to list user online last 24 hour.
How can i do this?

Thanx

Try this:

Admin >> Features and Options >> Change the "User online time threshold" to 1440 if you want to show how many have been online in last 24 hours.
Title: Re: Users Online Today Mod
Post by: PrizeLive.com on June 28, 2006, 10:34:18 AM
Once you install this, how can you disable it?
Title: Re: Users Online Today Mod
Post by: Gobo on June 28, 2006, 12:18:36 PM
just remove it from the board index template and it will be gone :D
Title: Re: Users Online Today Mod
Post by: Fatih! on June 28, 2006, 01:27:52 PM
Quote from: SurfExcelerator.com on June 28, 2006, 10:13:33 AM

Try this:

Admin >> Features and Options >> Change the "User online time threshold" to 1440 if you want to show how many have been online in last 24 hours.
Yes, i know it but i want to view last ten minute and 24 hour online list
Title: Re: Users Online Today Mod
Post by: carola0102 on June 29, 2006, 02:23:11 AM
Quote from: DemonicInfluence on June 26, 2006, 07:02:19 PM
only edit boardindex.template.php

thank you so much, but what should I edit there?
Title: Re: Users Online Today Mod
Post by: PrizeLive.com on June 29, 2006, 09:09:16 AM
Quote from: akulion on June 28, 2006, 12:18:36 PM
just remove it from the board index template and it will be gone :D

Isn't there an admin function to disable it?
Title: Re: Users Online Today Mod
Post by: L.G.S on July 01, 2006, 08:38:23 AM
Admin disable would be a nice feature in the next version, if there is one
Title: Re: Users Online Today Mod
Post by: carola0102 on July 02, 2006, 12:10:40 PM
Quote from: carola0102 on June 25, 2006, 06:50:11 AM
I'm using chatbubbles theme.. how to make this mod visible after installing it? Should I edit only the BoardIndex.template.php? And what exactly should I edit? I read the guidelines on this forum. But still I couldnt make it :-[ Can anyone please help?

Thanks in advance,
Carola

anyone?
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on July 03, 2006, 11:48:11 AM
Umm... In the install.xml there is a section for boardindex.template.php... Then just do the edits..
Title: Re: Users Online Today Mod
Post by: L.G.S on July 04, 2006, 04:56:34 PM
Hey, I'm trying to add this mod to Dilber MC theme, but I'm having this problem.

<file name="$themedir/BoardIndex.template.php">
<operation>
<search position="replace"><![CDATA[
<td class="windowbg2">
<b><a href="', $board['href'], '" name="b', $board['id'], '">', $board['name'], '</a></b><br />
]]></search>
<add><![CDATA[
<td class="windowbg2"', $board['is_redirect'] && $modSettings['redirect_hide_columns'] ? ' colspan="2"' : '' , '>
<b><a href="', $board['href'], '" name="b', $board['id'], '"', ($board['is_redirect'] && $board['redirect_target'] != '') ? ' target="' . $board['redirect_target'] . '"' : '' , '>', $board['name'], '</a></b><br />
]]></add>


Except I have a problem..

This is the code in Dilber MC:

<td class="windowbg2" style="padding-top:12px; padding-bottom:12px;">

So what would I need to do to change this part so it works without template errors?
Title: Re: Users Online Today Mod
Post by: DemonicInfluence on July 05, 2006, 06:17:12 AM
no. Just add the part below.
Title: Re: Users Online Today Mod
Post by: AbsolutelyFreeWeb on July 05, 2006, 09:33:07 AM
So there are two versions:

1.3.1 that shows online users to guests
1.4.0 beta that does not

but both work on 1.1 rc2 ?
Title: Re: Users Online Today Mod
Post by: Bigguy on July 05, 2006, 10:06:49 AM
Yes thats correct. I don`t think I would use the beta on a live site though.
Title: Re: Users Online Today Mod
Post by: L.G.S on July 05, 2006, 10:52:28 AM
Oops sorry I posted my problem in the wrong forum
Title: Re: Users Online Today Mod
Post by: Carceri on July 06, 2006, 07:55:09 AM
The beta version was meant to test out new features, and hence it should not be used for production systems. However, lack of time on my side has meant that I have not added new features to it in a long time, only fixed bugs as they appeared. This means that the current beta is actually the most bug-free version of this mod so far :)
Title: Re: Users Online Today Mod
Post by: PacificWx on July 20, 2006, 11:44:48 AM
I was told to post here with my query:

SMF Version: SMF 1.1 RC2
Not really causing any problems - just showing up a lot in my error log.

Undefined index: uot_users_online_today_title
File: /home/pacificw/public_html/forum/Themes/default/BoardIndex.template.php (eval?)
Line: 484

Any particular fix to this?
Title: Re: Users Online Today Mod
Post by: SpyDie on July 20, 2006, 11:49:46 AM
That would be caused by whatever user created that error, whatever theme he is using doesn't have the following strings in Modifications.english.php:

Quote// Users Online Today Mod
$txt['uot_users_online_today_title']='Users Logged In Today';
$txt['uot_total_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';

Make sure in each of your themes you have this in the Themes/*themename*/languages/Modifications.english.php file.
Title: Re: Users Online Today Mod
Post by: PacificWx on July 20, 2006, 11:53:28 AM
ok, I will look at that - thank you :)

Edited to add - fixed it up good and proper - thanks for that!
Title: Re: Users Online Today Mod
Post by: fiver on July 21, 2006, 03:59:24 AM
Hi Carceri,

1. The alt="Users Online Users Logged In Today" is still there when installed with 1.40beta2.
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />

I've changed mine to alt="Users Logged In Today"
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today_title'], '" border="0" />

2. Since the Title and the Alt are using the same words "Users Logged In Today", there is no need to have 2 variables in Modifications.english.php
$txt['uot_users_online_today_title']='Users Logged In Today';
$txt['uot_total_users_online_today']='Users Logged In Today';


Maybe a $txt['uot_ulit'] will do?
$txt['uot_ulit']='Users Logged In Today';

SMF does it that way too for "Users Online", by using the same variable $txt[158] for Title and Alt.
// "Users online" - in order of activity.
echo '
<tr>
<td class="titlebg" colspan="2">', $txt[158], '</td>
</tr><tr>
<td rowspan="2" class="windowbg" width="20" valign="middle" align="center">
', $context['show_who'] ? '<a href="' . $scripturl . '?action=who">' : '', '<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], '" />', $context['show_who'] ? '</a>' : '', '
</td>
<td class="windowbg2" width="100%">';


;)
Title: Re: Users Online Today Mod
Post by: BMRMorph on July 21, 2006, 12:01:43 PM
*gruml*
seems that i'm some kind of stupid...
i c<nt get it to work with the babylon theme. i did a few code changes to support german
language and in default it works but in babylon...
so this is a request to Carceri:
maybe you could include the required changes to the babylon script in your next release?
(it seems a good idea in two ways for me 1. it solves my problem *g* 2. the babylon theme
is also like the default theme shiped with the smf download :) )
Title: Re: Users Online Today Mod
Post by: Carceri on July 21, 2006, 03:59:35 PM
Quote from: fivearts on July 21, 2006, 03:59:24 AM
1. The alt="Users Online Users Logged In Today" is still there when installed with 1.40beta2.

2. Since the Title and the Alt are using the same words "Users Logged In Today", there is no need to have 2 variables in Modifications.english.php

Yes, I know these two. I thought I fixed them ages ago, but apparently I only did it for the version here on my harddisk :)
Title: Re: Users Online Today Mod
Post by: Carceri on July 21, 2006, 04:01:18 PM
Quote from: BMRMorph on July 21, 2006, 12:01:43 PM
maybe you could include the required changes to the babylon script in your next release?

For the time being, I only make the required changes for the default theme, sorry. It's simply due to lack of time.
Title: Re: Users Online Today Mod
Post by: xxx on July 22, 2006, 04:24:43 PM
Is there a version who works with 1.0.7 ???
Title: Re: Users Online Today Mod
Post by: BMRMorph on July 23, 2006, 05:00:51 AM
Quote from: Carceri on July 21, 2006, 04:01:18 PM
For the time being, I only make the required changes for the default theme, sorry. It's simply due to lack of time.
Mhh, i can understand that, in some cases nothing other than me *g*
but in that case could someone post which changes exactly have to made to the babylon theme.
I know, there are some sugestions which should work to all themes
I paste that code above the "// If they are logged in, but SP1..." line but that does just an output like in that post (http://www.simplemachines.org/community/index.php?topic=55513.msg566981#msg566981) (and below).
Title: Re: Users Online Today Mod
Post by: BeoR on July 24, 2006, 03:54:45 PM
Is there a way to make it work at the "statistics center" instead of at the board index? I can't seem to make it "list" the users who logged in for the day.

http://www.istorya.net/forums/index.php?action=stats - I placed it just above the "Forum History"
Title: Re: Users Online Today Mod
Post by: Carceri on July 24, 2006, 07:10:50 PM
Quote from: BeoR on July 24, 2006, 03:54:45 PM
Is there a way to make it work at the "statistics center" instead of at the board index? I can't seem to make it "list" the users who logged in for the day.

That's because that list is only built in BoardIndex.php whereas Stats.php is loaded for the stats center. Stats.php only counts the total number of users logged in that day and does not build the list.

If you want to change this, take a look at the changes made in BoardIndex.php and apply them to Stats.php also.
Title: Re: Users Online Today Mod
Post by: BeoR on July 24, 2006, 11:47:36 PM
I did everything the mod does to BoardIndex.php to stats.template.php. It already displays the static texts but it doesn't display the dynamic data.
Title: Re: Users Online Today Mod
Post by: Joshsux on August 01, 2006, 01:37:34 AM
can anybody please explain what code i need to find and where i need to put it in my custom theme file? i'm lost and i keep getting board errors because im doing it wrong please help me do it
Title: Re: Users Online Today Mod
Post by: SpyDie on August 01, 2006, 06:33:02 AM
This explains it simple enough:

http://www.simplemachines.org/community/index.php?topic=55513.msg575925#msg575925

Just edit the BoardIndex.template.php file in each of your Themes folders like said there.
Title: Re: Users Online Today Mod
Post by: Joshsux on August 02, 2006, 01:47:43 AM
Thanks, i found it and it works fine now mate.

Edit: is there anyway to make the number of people number on the same line as the people? atm it looks like this:

4 :
NAME, NAME, NAME, NAME

Anyway to make it like

4 : NAME, NAME, NAME, NAME   

Would look better wouldn't it?
Title: Re: Users Online Today Mod
Post by: Joshsux on August 09, 2006, 01:48:53 AM
Quote from: rsj1 on May 20, 2006, 11:02:56 AM
;D Many thanks it worked a treat!

Quote from: Carceri on May 18, 2006, 07:20:56 AM
Quote from: rsj1 on May 17, 2006, 04:51:00 PM
Is there a way to make this hack (I'm using 1.4 beta) with the default skin show users online in the last 24 hours (IE keep cycling around instead of resetting at midnight)? Any help or suggestions would be most appreciated ;)

That should be easy. In BoardIndex.php find


$nowdate = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);


And replace with


$midnight = time() - 86400;


And in Stats.php find


$frag = explode('-', strftime('%Y-%m-%d', time()));
$midnight = forum_time(false, mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]));


and replace with


$midnight = time() - 86400;


Also edit Modifications.english.php to the appropriate text you want displayed

im using the Aa_New_Damage and i wanna do what he is doing with the 24 hour thing instead of midnight right, but i don't have a stats.php? i also can't find that code.
Title: Re: Users Online Today Mod
Post by: Carceri on August 09, 2006, 05:18:14 PM
Quote from: Joshsux on August 09, 2006, 01:48:53 AM
but i don't have a stats.php?

Yes you do. It's a part of SMF, not the themes.
Title: Re: Users Online Today Mod
Post by: Joshsux on August 09, 2006, 11:23:57 PM
oh ok lol, so any idea how to get it working with this theme? i got it working i mean to make it so its 24 hour loop, i dont have any of the file but maybe stats.php will that work?
Title: Re: Users Online Today Mod
Post by: Carceri on August 10, 2006, 02:21:42 AM
Quote from: Joshsux on August 09, 2006, 11:23:57 PM
oh ok lol, so any idea how to get it working with this theme? i got it working i mean to make it so its 24 hour loop, i dont have any of the file but maybe stats.php will that work?

No, you have to change BoardIndex.php for that as mentioned above. Note that this file is NOT the same as BoardIndex.template.php
Title: Re: Users Online Today Mod
Post by: Joshsux on August 11, 2006, 01:55:51 AM
mmmm hmmmm and where do i find this "BoardIndex.php" as i can't find it NO WHERE in my FTP....? why do people help but only give little replies thinking people know everything how the hell am i suppose to know where this file is?
Title: Re: Users Online Today Mod
Post by: Bigguy on August 11, 2006, 02:02:09 AM
umm, I do believe it is in the Sources folder, were you have installed your forum.
Title: Re: Users Online Today Mod
Post by: Carceri on August 12, 2006, 06:02:13 PM
Quote from: Joshsux on August 11, 2006, 01:55:51 AM
why do people help but only give little replies thinking people know everything how the hell am i suppose to know where this file is?

Well, it appears as if you found Stats.php. BoardIndex.php is in the same directory, so I assumed that would be equally easy to find :)
Title: Re: Users Online Today Mod
Post by: Joshsux on August 12, 2006, 10:37:18 PM
Yeeh hey i got it to work thanks you guys for helping me  8)
Title: Re: Users Online Today Mod
Post by: deadpoeticstar on August 14, 2006, 12:09:08 PM
could this be about ready for an RC3 update?
Title: Re: Users Online Today Mod
Post by: Carceri on August 15, 2006, 04:06:26 AM
Quote from: deadpoeticstar on August 14, 2006, 12:09:08 PM
could this be about ready for an RC3 update?

Sure, as soon as SMF RC3 is released I will make this mod compatible with it.
Title: Re: Users Online Today Mod
Post by: kittykatt on August 15, 2006, 01:28:18 PM
Sorry if I am missing something... but when will it be ready for SMF 1.0.7.?
Title: Re: Users Online Today Mod
Post by: Carceri on August 15, 2006, 01:42:12 PM
It will never be ready for 1.0. It will be ready for 1.1 when it is released.

I have also added a version for 1.1 RC3 now, but since there are no changes between RC2 and RC3 in the files that this mod affects, that version should also be compatible with RC2.
Title: Re: Users Online Today Mod
Post by: ckgb on August 24, 2006, 08:26:29 PM
Thank you very much for RC3 virsion of the mod.

I understand by default only registered users can see the names in the users today list.

Where can I change the permissions so that everybody is able to see the full list and not the number alone.
Title: Re: Users Online Today Mod
Post by: Carceri on August 25, 2006, 01:44:12 AM
Quote from: ckgb on August 24, 2006, 08:26:29 PM
Where can I change the permissions so that everybody is able to see the full list and not the number alone.

Edit BoardIndex.template and remove the line that says

if (!$context['user']['is_guest'])

Also, change the line

if (!empty($context['users_online_today']) && !$context['user']['is_guest'])

to

if (!empty($context['users_online_today']))

That should do it (although I have not tested)

Title: Re: Users Online Today Mod
Post by: ckgb on August 25, 2006, 03:21:35 AM
It did the trick. Thank you very much.
Title: Re: Users Online Today Mod
Post by: scottws on August 26, 2006, 12:08:56 AM
Quote from: Carceri on May 18, 2006, 07:20:56 AM
Quote from: rsj1 on May 17, 2006, 04:51:00 PM
Is there a way to make this hack (I'm using 1.4 beta) with the default skin show users online in the last 24 hours (IE keep cycling around instead of resetting at midnight)? Any help or suggestions would be most appreciated ;)

That should be easy. In BoardIndex.php find


$nowdate = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);


And replace with


$midnight = time() - 86400;


And in Stats.php find


$frag = explode('-', strftime('%Y-%m-%d', time()));
$midnight = forum_time(false, mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]));


and replace with


$midnight = time() - 86400;


Also edit Modifications.english.php to the appropriate text you want displayed

I am interested in also using this mod to represent the users online in the last 24 hours instead of the last day with a reset at 12:00am.

However, 'm not finding this code to edit mentioned in the files.  I searched ./Sources/BoardIndex.php by "nowdate" and it found nothing.  I also searched ./Sources/Stats.php by "frag" and by "explode" and found nothing. I just installed the newest version of this mod on 1.1 RC3 three days ago.

Here is what I am finding in ./Sources/BoardIndex.php that might be similar:

$date = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $date['mon'], $date['mday'], $date['year']) - ($modSettings['time_offset'] * 3600);


As for ./Sources/Stats.php, I wasn't sure I could find what you were instructing, so I am posting all of what I found that seems to be related to this mod:

// Members online so far today.
$result = db_query("
SELECT mostOn
FROM {$db_prefix}log_activity
WHERE date = $date
LIMIT 1", __FILE__, __LINE__);
list ($context['online_today']) = mysql_fetch_row($result);
mysql_free_result($result);

$context['online_today'] = (int) $context['online_today'];

// Total members online today
$date = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $date['mon'], $date['mday'], $date['year']) - ($modSettings['time_offset'] * 3600);
$result = db_query("
SELECT
COUNT(*)
FROM {$db_prefix}members
WHERE lastLogin >= $midnight", __FILE__, __LINE__);
list ($context['total_users_online_today']) = mysql_fetch_row($result);


Has the code used in the mod changed since the quoted post was made?  What do I have to change to get my idea to work?
Title: Re: Users Online Today Mod
Post by: Carceri on August 26, 2006, 05:57:30 AM
Quote from: scottws on August 26, 2006, 12:08:56 AM
Has the code used in the mod changed since the quoted post was made?  What do I have to change to get my idea to work?

Yes, the code has changed, but it should be even simpler. Just look for

$date = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $date['mon'], $date['mday'], $date['year']) - ($modSettings['time_offset'] * 3600);

instead.
Title: Re: Users Online Today Mod
Post by: scottws on August 26, 2006, 04:41:34 PM
Quote from: Carceri on August 26, 2006, 05:57:30 AM
Quote from: scottws on August 26, 2006, 12:08:56 AM
Has the code used in the mod changed since the quoted post was made?  What do I have to change to get my idea to work?

Yes, the code has changed, but it should be even simpler. Just look for

$date = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $date['mon'], $date['mday'], $date['year']) - ($modSettings['time_offset'] * 3600);

instead.

So, I'm just changing the midnight part, right?
Title: Re: Users Online Today Mod
Post by: Carceri on August 26, 2006, 07:23:26 PM
Quote from: scottws on August 26, 2006, 04:41:34 PM
So, I'm just changing the midnight part, right?

Yes, and you can remove the line above as well
Title: Re: Users Online Today Mod
Post by: scottws on August 27, 2006, 10:34:34 AM
Thanks.
Title: Re: Users Online Today Mod
Post by: Badelehrling on August 30, 2006, 01:46:17 PM
Hi,

will you make a version compatible with 1.0.8? I tried all versions to install on my testforum. But no one worked :(

Greetz,
Badelehrling
Title: Re: Users Online Today Mod
Post by: Carceri on September 02, 2006, 07:01:11 AM
Quote from: Badelehrling on August 30, 2006, 01:46:17 PM
will you make a version compatible with 1.0.8? I tried all versions to install on my testforum. But no one worked :(

No I won't. That question has been answered countless times before. Hopefully 1.1 will soon be released, and then I will support an official release of SMF :)
Title: Re: Users Online Today Mod
Post by: SpyDie on September 03, 2006, 01:41:28 PM
Any ideas why the Online List is no longer clickable after applying it into the Dilber Theme?

Screenshot: http://www.landzdown.com/UsersOnline.jpg

I expect it is something rather simple...
Title: Re: Users Online Today Mod
Post by: Fiery on September 12, 2006, 09:38:18 PM
Hello,

I looked through the posts and could not find a solution to this.

On one of my message boards it shows

6 :
user names

How do I change the 6, to "Users online today"?

---

Also, on another message board how to I change Users Seen Today, to Users online today?

Thank you,

Brian
Title: Re: Users Online Today Mod
Post by: Carceri on September 17, 2006, 06:09:18 AM
Quote from: pmp6nl on September 12, 2006, 09:38:18 PM
On one of my message boards it shows

6 :
user names

How do I change the 6, to "Users online today"?

Seems you are missing some language settings. What language are you using? If you are using something else than english, you need to make the changes manually.

Quote from: pmp6nl on September 12, 2006, 09:38:18 PM
Also, on another message board how to I change Users Seen Today, to Users online today?

Users Seen Today was the text in an earlier version of this mod. You can either change the same language file or upgrade to the latest version of this mod.
Title: Re: Users Online Today Mod
Post by: Fiery on September 18, 2006, 12:59:33 PM
Quote from: Carceri on September 17, 2006, 06:09:18 AM
Quote from: pmp6nl on September 12, 2006, 09:38:18 PM
On one of my message boards it shows

6 :
user names

How do I change the 6, to "Users online today"?

Seems you are missing some language settings. What language are you using? If you are using something else than english, you need to make the changes manually.

Quote from: pmp6nl on September 12, 2006, 09:38:18 PM
Also, on another message board how to I change Users Seen Today, to Users online today?

Users Seen Today was the text in an earlier version of this mod. You can either change the same language file or upgrade to the latest version of this mod.

I am using english, what do I need to do?
Title: Re: Users Online Today Mod
Post by: gianni77 on September 19, 2006, 01:18:33 PM
great mod !

But what i would like to see is the names of male and female in different color
or is this something beyond the mod?
Title: Re: Users Online Today Mod
Post by: Skipdawg on September 19, 2006, 01:46:58 PM
What you could do there to take advantage of this mod is create a group for male and female and make there color group what you want and the mod will pickup on that and show that.  ;)
Title: Re: Users Online Today Mod
Post by: gianni77 on September 19, 2006, 01:52:27 PM
lol ...simple but effective

thank's  :D
Title: Re: Users Online Today Mod
Post by: steve in houston on September 19, 2006, 08:21:07 PM
i made a mod that works for 1.0.8.

it shows all users active in last 24 hours and
also shows member group colors.

i havent packaged it up yet but i can.

you can see it in action at http://www.stucknut.com/jimrome (http://www.stucknut.com/jimrome)
Title: Re: Users Online Today Mod
Post by: Badelehrling on September 20, 2006, 08:52:19 AM
Quote from: steve in houston on September 19, 2006, 08:21:07 PM
i havent packaged it up yet but i can.

This would be very nice :) I'm using SMF 1.0.8 and I would really like to use this mod :)
Title: Re: Users Online Today Mod
Post by: haktanir2 on September 20, 2006, 05:27:20 PM
Excellent mod, tyvm!  :D
Title: Re: Users Online Today Mod
Post by: qd-race on September 23, 2006, 10:36:46 AM
I cannot find the file and and code where this package add in default theme. I want to mod to the other custom theme. Please help.
Title: Re: Users Online Today Mod
Post by: codenaught on September 23, 2006, 10:45:33 AM
Quote from: qd-race on September 23, 2006, 10:36:46 AM
I cannot find the file and and code where this package add in default theme. I want to mod to the other custom theme. Please help.
It's in "Users_Online_Today_Mod.xml".

Search for
<file name="$themedir/BoardIndex.template.php" error="fatal">
Title: Re: Users Online Today Mod
Post by: qd-race on September 23, 2006, 11:11:00 AM
If it call BoardIndex.template.php from theme directory, why no result with the other custom theme like Babylon Theme. Is this $themedir is default theme. How to add to other custom theme?
Title: Re: Users Online Today Mod
Post by: codenaught on September 23, 2006, 11:30:19 AM
You need to manually apply it. Look at the bit I pointed to, open a text editor and do the search and replace for the custom theme's BoardIndex.template.php file.

This might help: How to make mods work with themes? (http://www.simplemachines.org/community/index.php?topic=34526.0)
Title: Re: Users Online Today Mod
Post by: qd-race on September 23, 2006, 12:54:59 PM
Thanks. At last, already managed to custom mod the package in other theme.
Anybody want to add this mode to their Babylon and Classic YaBB Theme?
Title: Re: Users Online Today Mod
Post by: edi67 on September 24, 2006, 10:48:25 AM
one question, mod work perfectly but in my forum i see user online today not soerted for name , and i show than in random way, is possible see them sorted for name?

look
www.crazyzone.ws
Title: Re: Users Online Today Mod
Post by: codenaught on September 24, 2006, 10:57:01 AM
Quote from: edi67 on September 24, 2006, 10:48:25 AM
one question, mod work perfectly but in my forum i see user online today not soerted for name , and i show than in random way, is possible see them sorted for name?

look
www.crazyzone.ws
It is not random. It is by the time they last logged in.

This is untested, but you can try changing in Sources/BoardIndex.php

$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(

to

$context['users_online_today'][$row['memberName']] = array(
Title: Re: Users Online Today Mod
Post by: edi67 on September 25, 2006, 05:38:43 PM
Quote from: akabugeyes on September 24, 2006, 10:57:01 AM
Quote from: edi67 on September 24, 2006, 10:48:25 AM
one question, mod work perfectly but in my forum i see user online today not soerted for name , and i show than in random way, is possible see them sorted for name?

look
www.crazyzone.ws
It is not random. It is by the time they last logged in.

This is untested, but you can try changing in Sources/BoardIndex.php

$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(

to

$context['users_online_today'][$row['memberName']] = array(

i tried but nothing changed always the same
Title: Re: Users Online Today Mod
Post by: steve in houston on September 28, 2006, 12:12:46 AM
I packaged up a similar mod for 1.0.8.
I'm just waiting for approval.

http://mods.simplemachines.org/index.php?mod=479 (http://mods.simplemachines.org/index.php?mod=479)
Title: Re: Users Online Today Mod
Post by: AbsolutelyFreeWeb on October 08, 2006, 03:56:38 PM
Finexe Mod made for tech blue theme has been rejected since it contains code from an old version of your mod.  Could I have your permission to use your code in the tech blue theme mod ?
See http://mods.simplemachines.org/index.php?mod=375
Title: Re: Users Online Today Mod
Post by: MoreBloodWine on October 16, 2006, 12:12:01 AM
Users Logged In Today

The above is the default text one sees in the info center... how can one change it to say something else... like you can do with the MCL (Membergroup Color Legend) mod...
Title: Re: Users Online Today Mod
Post by: Vinspire on October 16, 2006, 10:02:23 AM
Quote from: MoreBloodWine on October 16, 2006, 12:12:01 AM
Users Logged In Today

The above is the default text one sees in the info center... how can one change it to say something else... like you can do with the MCL (Membergroup Color Legend) mod...

Look into ur Modifications.english.php under languages folder.
Title: Re: Users Online Today Mod
Post by: MoreBloodWine on October 16, 2006, 03:18:32 PM
Thx ill give that a shot here in a bit and post if it worked ;-)
Title: Re: Users Online Today Mod
Post by: danskmacabre on November 07, 2006, 03:22:52 AM
Just installed this mod on the default theme.
It installed and worked fine.

All I need to do is change my helios theme to include this mod, which I will do tonight.

Thanks for this mod, it's very nice.

Title: Re: Users Online Today Mod
Post by: danskmacabre on November 08, 2006, 03:20:44 PM
was very easy to manually add to the helios theme.
Works perfectly.
Title: Re: Users Online Today Mod
Post by: rockinaway on November 12, 2006, 08:06:23 AM
Can this shows number of guests and spiders which have visited?
Title: Re: Users Online Today Mod
Post by: ArkServer on November 14, 2006, 01:19:17 PM
Quote from: rockinaway on November 12, 2006, 08:06:23 AM
Can this shows number of guests and spiders which have visited?

That, and how do i make it so that guests can also see the users online today instead of only an integer.
Title: Re: Users Online Today Mod
Post by: Vinspire on November 17, 2006, 07:06:56 AM
Quote from: ArkServer on November 14, 2006, 01:19:17 PM
That, and how do i make it so that guests can also see the users online today instead of only an integer.

I second this statement.
Title: Re: Users Online Today Mod
Post by: Carceri on November 17, 2006, 07:25:40 AM
It has been mentioned before in this thread. Unfortunately I can't remember exactly where, by try using the search.
Title: Re: Users Online Today Mod
Post by: Vinspire on November 17, 2006, 07:39:17 AM
Quote from: Carceri on August 25, 2006, 01:44:12 AM
Edit BoardIndex.template and remove the line that says

if (!$context['user']['is_guest'])

Also, change the line

if (!empty($context['users_online_today']) && !$context['user']['is_guest'])

to

if (!empty($context['users_online_today']))

That should do it (although I have not tested)

Is this the one ?
Title: Re: Users Online Today Mod
Post by: Carceri on November 17, 2006, 07:41:50 AM
It looks like it, but I have still not tested it :)
Title: Re: Users Online Today Mod
Post by: Vinspire on November 17, 2006, 10:00:27 PM
Quote from: Carceri on November 17, 2006, 07:41:50 AM
It looks like it, but I have still not tested it :)

Just tested it and everything working smoothly. Thanks Carceri :)
Title: Re: Users Online Today Mod
Post by: L.G.S on December 01, 2006, 09:14:57 AM
what would I need to change to have this as "Users online this week" ?

(not just words, the actual recording as well)
Title: Re: Users Online Today Mod
Post by: sager on December 07, 2006, 01:37:34 PM
waiting for 1.1 compatible
Title: Re: Users Online Today Mod
Post by: Carceri on December 07, 2006, 01:39:43 PM
Quote from: sager on December 07, 2006, 01:37:34 PM
waiting for 1.1 compatible

What exactly are you waiting for?
Title: Re: Users Online Today Mod
Post by: sager on December 07, 2006, 01:44:39 PM
the text doesnt show up..... when i install it on my forums. as in "USERS ONLINE TODAY " i can see the names but not the saying user online today .texts and even the header
Title: Re: Users Online Today Mod
Post by: Carceri on December 07, 2006, 01:50:25 PM
It works fine for me on 1.1, so the mod is compatible with 1.1. Are you perhaps using a different language than english?
Title: Re: Users Online Today Mod
Post by: Gobo on December 07, 2006, 02:58:11 PM
add these language strings to your Modifications.english.php file in your themes Languages folder just before the ?> at the end


$txt['uot_users_online_today_title']='Users Seen Today';
$txt['uot_user_online_today']='user seen today';
$txt['uot_users_online_today']='users seen today';
$txt['uot_total_users_online_today']='Users Seen Today';
$txt['uot_yesterday']='Yesterday at ';
Title: Re: Users Online Today Mod
Post by: lupus on December 08, 2006, 05:40:26 AM
So that i don't try and spend hours doing this has anyone done the work for the Helios_multi theme and could tell me what i need to change and where??

Thanks folks...

Title: Re: Users Online Today Mod
Post by: sager on December 08, 2006, 07:28:52 AM
by by mistake installed english utf and english uk.... how can i change the language ??? maybe it will wrk tht time...
Title: Re: Users Online Today Mod
Post by: vipmoney on December 11, 2006, 12:33:22 AM

This MOD doesn't record on the database the Users Online today value for each days ? to be seen on the stats page ?
Title: Re: Users Online Today Mod
Post by: Carceri on December 11, 2006, 01:31:54 AM
Quote from: vipmoney on December 11, 2006, 12:33:22 AM

This MOD doesn't record on the database the Users Online today value for each days ? to be seen on the stats page ?

That's true
Title: Re: Users Online Today Mod
Post by: THE BRA1N on December 11, 2006, 11:43:15 PM
Quote from: danskmacabre on November 08, 2006, 03:20:44 PM
was very easy to manually add to the helios theme.
Works perfectly.

Can you give a step-by -step of what you did to make it work with helios?
Title: Re: Users Online Today Mod
Post by: vipmoney on December 12, 2006, 12:57:36 PM
Quote from: Carceri on December 11, 2006, 01:31:54 AM
Quote from: vipmoney on December 11, 2006, 12:33:22 AM

This MOD doesn't record on the database the Users Online today value for each days ? to be seen on the stats page ?

That's true

And anybody knows how to do that ?

Or is this part of the plans for the next versions of this MOD ? btw, this mod is awesome ;)
Title: Re: Users Online Today Mod
Post by: mcalan2001 on December 13, 2006, 02:39:52 PM
Quote from: akabugeyes on September 24, 2006, 10:57:01 AM
It is not random. It is by the time they last logged in.
This is untested, but you can try changing in Sources/BoardIndex.php

$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(

to

$context['users_online_today'][$row['memberName']] = array(

I think that needs to be much the same edit, but about ten lines down. However I'm no expert and it put the members in reverse alphabetic order. I couldn't see why. So I'll leave it to somebody who knows what they are doing. Please.  :D
Title: Re: Users Online Today Mod
Post by: FoneBone on December 14, 2006, 06:39:56 AM
Thx for this mod. I've moddified it a little, so it works with german language and the YaBB SE Classic Theme.
Title: Re: Users Online Today Mod
Post by: Carceri on December 14, 2006, 07:06:02 AM
Quote from: vipmoney on December 12, 2006, 12:57:36 PM
And anybody knows how to do that ?

Or is this part of the plans for the next versions of this MOD ? btw, this mod is awesome ;)

I don't know how to do it, but I am sure that given the time I could figure it out :-) I will not rule out that it might be added to a future version of this mod, but I don't want to make any promises. We'll see what my time permits.
Title: Re: Users Online Today Mod
Post by: wickedstangs on December 14, 2006, 08:14:32 PM
Question I removed all my board threads from guest. But when I log in I see guest logged in too.  What is that?
Title: Re: Users Online Today Mod
Post by: vipmoney on December 15, 2006, 02:51:53 AM
Quote from: Carceri on December 14, 2006, 07:06:02 AM
Quote from: vipmoney on December 12, 2006, 12:57:36 PM
And anybody knows how to do that ?

Or is this part of the plans for the next versions of this MOD ? btw, this mod is awesome ;)

I don't know how to do it, but I am sure that given the time I could figure it out :-) I will not rule out that it might be added to a future version of this mod, but I don't want to make any promises. We'll see what my time permits.

Thanks a lot ;)
Title: Re: Users Online Today Mod
Post by: nitins60 on December 18, 2006, 06:41:02 PM
can you add a feature of displaying small icon next to username? That icon refers to the browser they used. It's already available in vB. So can you add it as an extra option. It looks cool with small browser icons!
Title: Re: Users Online Today Mod
Post by: Stuart on December 21, 2006, 06:56:07 AM
I'd rather have the users in alphabetic order instead of time. Anyone an idea what I've to change to get the users in that specific order?

Cheers!
Title: Re: Users Online Today Mod
Post by: kross on December 22, 2006, 10:26:48 AM
can anyone help me, I want to use this mode for multylanguage forum, so I need to know how to do that.

languages: english-ut8, serbian-utf8 and croatian-utf8

I'm usin SMF 1.1.1 and I managed only to point to english-utf8, so I can see:
Total: 56 (Visible: 53, Hidden: 3)

but, when I swich to other then english-utf8, I get this:      
: 56 (: 53, : 3)

I now it's something easy, but can't remeber how ::)

thanks.
Title: Re: Users Online Today Mod
Post by: Stuart on December 22, 2006, 11:40:10 AM
Quote from: kross on December 22, 2006, 10:26:48 AM
can anyone help me, I want to use this mode for multylanguage forum, so I need to know how to do that.

languages: english-ut8, serbian-utf8 and croatian-utf8

I'm usin SMF 1.1.1 and I managed only to point to english-utf8, so I can see:
Total: 56 (Visible: 53, Hidden: 3)

but, when I swich to other then english-utf8, I get this:      
: 56 (: 53, : 3)

I now it's something easy, but can't remeber how ::)

thanks.

Probably you have to add (translate first) the information (given below) into the Language Files (default theme) called Modifications.english.php (were it says English any language you have).

$txt['uot_users_online_today_title']='Users Seen Today';
$txt['uot_user_online_today']='user seen today';
$txt['uot_users_online_today']='users seen today';
$txt['uot_total_users_online_today']='Users Seen Today';
$txt['uot_yesterday']='Yesterday at ';
Title: Re: Users Online Today Mod
Post by: FoneBone on December 22, 2006, 11:54:22 AM
I think Stuart is right. The path to these files should be : Themes/default/languages/
And the names of them are maybe Modifications.serbian-utf8.php and Modifications.croatian-utf8.php.
Title: Re: Users Online Today Mod
Post by: sanax on December 22, 2006, 03:38:21 PM
Anyone has an idea how to add the 'Users online today' in the TPortal stats block? Thought it would be neat to add the list below the 'Users online' list in this block? Any ideas?
Title: Re: Users Online Today Mod
Post by: Vinspire on December 23, 2006, 02:50:29 AM
Is it compatible wif SMF 1.1.1 ?
Title: Re: Users Online Today Mod
Post by: Carceri on December 23, 2006, 05:09:31 AM
Quote from: Vinspire on December 23, 2006, 02:50:29 AM
Is it compatible wif SMF 1.1.1 ?

Yes it is
Title: Re: Users Online Today Mod
Post by: Vinspire on December 26, 2006, 12:41:45 AM
Quote from: Carceri on December 23, 2006, 05:09:31 AM
Quote from: Vinspire on December 23, 2006, 02:50:29 AM
Is it compatible wif SMF 1.1.1 ?

Yes it is

Thanks :)
Title: Re: Users Online Today Mod
Post by: efish on December 27, 2006, 04:17:48 PM
Hey. My site uses 1.1.1 and we installed the mod but we are using a custom theme (Mercury), so can someone please tell us how to edit the file, etc.... to get the mod running on our site? Thanks for this, it looks great...excited to add it to my site!
Title: Re: Users Online Today Mod
Post by: Webrunner on December 27, 2006, 05:31:55 PM
Quote from: mcalan2001 on December 13, 2006, 02:39:52 PM
Quote from: akabugeyes on September 24, 2006, 10:57:01 AM
It is not random. It is by the time they last logged in.
This is untested, but you can try changing in Sources/BoardIndex.php

$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(

to

$context['users_online_today'][$row['memberName']] = array(

I think that needs to be much the same edit, but about ten lines down. However I'm no expert and it put the members in reverse alphabetic order. I couldn't see why. So I'll leave it to somebody who knows what they are doing. Please.  :D

Find:

krsort($context['users_online_today']);
krsort($context['list_users_online_today']);


change into:

ksort($context['users_online_today']);
ksort($context['list_users_online_today']);


and the reverse sorting is over ;)
Title: Re: Users Online Today Mod
Post by: mariz26 on December 28, 2006, 05:10:12 AM
Im using RC 3 1.1 here in my forum www.monetaryjournal.com
I have downloaded twice this mod and yet its giving a test failed on 2 files so I didn't continue to install.  Please help
Title: Re: Users Online Today Mod
Post by: veldfire on December 28, 2006, 10:25:49 AM
I am using a few other mods as well and am running into an issue as these two parts are duplicated but not identical

Other Mod:
// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online']))
echo '
', $txt[140], ':<br />', implode(', ', $context['list_users_online']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


Users Online Today Mod:
// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


Any idea how I can rectify this ?

TIA,
Veldfire
Title: Re: Users Online Today Mod
Post by: njoker555 on December 29, 2006, 10:23:56 PM
well im trying to get this working with aa new damage by m3talc0re, and what do i have to edit to fix this?  http://www.gamers-forum.com is the link, and i cant read through 34 pages of posts to find out, i have no time for that right now :(
Title: Re: Users Online Today Mod
Post by: nitins60 on December 29, 2006, 11:30:47 PM
Quote from: nitins60 on December 18, 2006, 06:41:02 PM
can you add a feature of displaying small icon next to username? That icon refers to the browser they used. It's already available in vB. So can you add it as an extra option. It looks cool with small browser icons!
Title: Re: Users Online Today Mod
Post by: Lord_Haart on December 30, 2006, 08:02:17 AM
I've installed this mod and works fine on default Theme with version 1.1.1, but I want it works with dilbermc Theme... how can I make it if dilbermc doesn't have a stats.template.php file??

Thanks ;)
Title: Re: Users Online Today Mod
Post by: kriskd on December 30, 2006, 08:10:15 AM
Quote from: Lord_Haart on December 30, 2006, 08:02:17 AM
I've installed this mod and works fine on default Theme with version 1.1.1, but I want it works with dilbermc Theme... how can I make it if dilbermc doesn't have a stats.template.php file??

Thanks ;)

I don't have a stats.template.php file with my custom template (basically the classic template) and it works fine.  As far as I understand, you only need to edit what theme files you have for your custom theme.  In my case, that was only BoardIndex.template.php.
Title: Re: Users Online Today Mod
Post by: Carceri on December 30, 2006, 08:18:29 AM
Quote from: nitins60 on December 29, 2006, 11:30:47 PM
can you add a feature of displaying small icon next to username? That icon refers to the browser they used. It's already available in vB. So can you add it as an extra option. It looks cool with small browser icons!

I haven't seen it in vB, but it sounds like it will just clutter the user interface. I like things simple, and I also like to have the list looking exactly like the "currenly online" users list.
Title: Re: Users Online Today Mod
Post by: njoker555 on January 01, 2007, 07:55:25 PM
how do i make this to show on a custom template?  is there a read me for it so i can maybe configure the template files or something?
Title: Re: Users Online Today Mod
Post by: Gobo on January 01, 2007, 08:31:45 PM
AFTER you install the mod using package manager

boardindex.template.php file is to simply look for this line:

// If they are logged in, but SP1 style information is off... show a personal message bar.

it occurs in all the themes --- just place the code above it





// Users online today
echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today_title'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

echo $context['num_users_online_today'], ' ', $context['num_users_online_today'] == 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo ':<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';




IF required then in Modifications.english.php right before the ?> place this code:



$txt['uot_users_online_today_title']='Users Seen Today';
$txt['uot_user_online_today']='user seen today';
$txt['uot_users_online_today']='users seen today';
$txt['uot_total_users_online_today']='Users Seen Today';
$txt['uot_yesterday']='Yesterday at ';

Title: Re: Users Online Today Mod
Post by: nitins60 on January 02, 2007, 12:10:31 AM
Quote from: Carceri on December 30, 2006, 08:18:29 AM
Quote from: nitins60 on December 29, 2006, 11:30:47 PM
can you add a feature of displaying small icon next to username? That icon refers to the browser they used. It's already available in vB. So can you add it as an extra option. It looks cool with small browser icons!

I haven't seen it in vB, but it sounds like it will just clutter the user interface. I like things simple, and I also like to have the list looking exactly like the "currenly online" users list.
it's not the basic feature! But a mod is available, many of them are using! Looks pretty good!
www.danya-mobile.com
you can see it, but it's non english site!
Title: Re: Users Online Today Mod
Post by: Gobo on January 02, 2007, 12:31:15 AM
well it may look good bur remember one thing - each extra icon, each extra line added is more queries for ur server.

Scripts which display a lot of things may 'look good' but they are usually very hard on the server
Title: Re: Users Online Today Mod
Post by: nitins60 on January 02, 2007, 03:11:28 AM
Atleast for ppl who are online, it's not gonna kill server! I always want to see the browsers ppl use mostly!
Title: Re: Users Online Today Mod
Post by: nitins60 on January 02, 2007, 03:11:57 AM
Atleast for ppl who are online, it's not gonna kill server! I always want to see the browsers ppl use mostly!
Title: Re: Users Online Today Mod
Post by: Gobo on January 02, 2007, 03:50:36 AM
try the k-description mod it shows the browsers on peoples posts

also u can use the custom who.template (posted somewhere around) which shows peoples browsers
Title: Re: Users Online Today Mod
Post by: Dejan on January 02, 2007, 07:51:40 AM
Is it possible to show a number of visitors online today, and not just number of users?

Title: Re: Users Online Today Mod
Post by: Webby on January 04, 2007, 09:15:07 AM
I saw there was a spider (Google bot) online on my board just now, but could these spiders / bots also be counted so you can see someting like :

total: 5 (Visible: 3, Hidden: 0, Spiders: 2)

Or something like that ??
Title: Re: Users Online Today Mod
Post by: Carceri on January 04, 2007, 09:18:35 AM
Quote from: Dejan on January 02, 2007, 07:51:40 AM
Is it possible to show a number of visitors online today, and not just number of users?

No. One could only do an approximation.
Title: Re: Users Online Today Mod
Post by: SvenJTD on January 07, 2007, 09:08:16 AM
I did what akulion wrote, and I altered all off my modification files for languages I use, and I just got a bar under the forum saying users seen today and nothing more. Am I missing something ???? Im using smf1.1.1 with the babilon theme
Thanks
Title: Re: Users Online Today Mod
Post by: Gobo on January 07, 2007, 09:46:17 AM
did u add the code for the board index template?

thats the most important part.

Also the mod MUST be installed before the modifications!
Title: Re: Users Online Today Mod
Post by: SvenJTD on January 07, 2007, 09:51:58 AM
I instaled the mod, even it told me it has an error, then I altered the board index file using your mentioned code above, then I altered the modificationd.language files I have - and nothing :(
Title: Re: Users Online Today Mod
Post by: Gobo on January 07, 2007, 09:54:32 AM
where did u get the error? in which file?

because it could be that an essential bit of code failed to be added to the SMf files
Title: Re: Users Online Today Mod
Post by: SvenJTD on January 07, 2007, 09:57:58 AM
ermmm, Im new at this - there is no error looking in the admin panel errors, it just gave me an error when I installed the package
Title: Re: Users Online Today Mod
Post by: Gobo on January 07, 2007, 10:15:28 AM
yup thats the error which needs to be known to be honest
without that there really isnt knowing which file wasnt edited.

And the mod not working for u is a pure indication that it wasnt installed properly.

Try and uninstall and see if it gives an error in a specific file
but dont proceed with the uninstall
Title: Re: Users Online Today Mod
Post by: SvenJTD on January 08, 2007, 02:17:26 AM
Sorry, had to go out.
The error that it gives me is "Modification parse error" on both of the files.

Cheers for the intrest in the problem.
Title: Re: Users Online Today Mod
Post by: Gobo on January 08, 2007, 04:28:39 AM
what are the names of the files?

can u just copy and paste the errors?
because it is essential to know which file the error occured on and then i can give u the mod instructions for this.

this mod applies changes to:
Stats.english.php
BoardIndex.php
Stats.php
BoardIndex.template.php
Stats.template.php
Modifications.english.php

so ull have to say which files are giving errors
Title: Re: Users Online Today Mod
Post by: SvenJTD on January 08, 2007, 05:51:46 AM
this is what errors I get:

SvenJTD    Today at 11:49:03 AM
83.131.167.96      01e132b498df2dd5a33227ee5d9a8758
h**p://www.fiatisti.hr/forum_smf/index.php?action=packages;sa=install2;package=Users_Online_Today_1.4.0.zip

2: file_get_contents(/mounted-storage/home13/sub006/sc10958/www.fiatisti.hr/forum_smf/Packages/temp/./Users_Online_Today_Mod.xml): failed to open stream: Success
File: /mounted-storage/home13/sub006/sc10958/www.fiatisti.hr/forum_smf/Sources/Packages.php
Line: 541
   
SvenJTD    Today at 11:49:03 AM
83.131.167.96      01e132b498df2dd5a33227ee5d9a8758
h**p://www.fiatisti.hr/forum_smf/index.php?action=packages;sa=install2;package=Users_Online_Today_1.4.0.zip

2: file_get_contents(): Unable to access /mounted-storage/home13/sub006/sc10958/www.fiatisti.hr/forum_smf/Packages/temp/./Users_Online_Today_Mod.xml
File: /mounted-storage/home13/sub006/sc10958/www.fiatisti.hr/forum_smf/Sources/Packages.php
Line: 541
Title: Re: Users Online Today Mod
Post by: Gobo on January 08, 2007, 06:58:36 AM
ur problem is related to permissions from what I can tell

Check that your Packages folder (in your forum root) is CHMODD to 777
Also inside check to see there is a folder called temp if not create one and chmod it to 777 as well.

To chmod a folder just right click the folder using your FTP manager and select 'properties' and click all the boxed and then OK
Title: Re: Users Online Today Mod
Post by: SvenJTD on January 08, 2007, 07:26:29 AM
The packages forler is set to 777 and I did not have the temp folder. After I created one it installed OK, deleted the temp folder and still nothing.

Once again thanks for the help.
Title: Re: Users Online Today Mod
Post by: Gobo on January 08, 2007, 07:58:02 AM
oh no keep the temp folder its required by almost all mods.

Did you get any errors on Install at all?

Also can you give a link to ur page so I can check itour what ur board index lookslike
Title: Re: Users Online Today Mod
Post by: SvenJTD on January 08, 2007, 09:43:47 AM
Heres the link: http://www.fiatisti.hr/forum_smf/index.php

and this is what he reported as an error
8: Undefined index: num_users_online_today
File: /mounted-storage/home13/sub006/sc10958/www.fiatisti.hr/forum_smf/Themes/default/BoardIndex.template.php (eval?)
Line: 413

: Undefined index: num_users_online_today
File: /mounted-storage/home13/sub006/sc10958/www.fiatisti.hr/forum_smf/Themes/default/BoardIndex.template.php (eval?)
Line: 413
Title: Re: Users Online Today Mod
Post by: SvenJTD on January 08, 2007, 09:59:00 AM
One other thing, I am now able to install all of the mods I want after I make a temp folder, but none of them is showing up :(

Can this and all others be related ?
Title: Re: Users Online Today Mod
Post by: Gobo on January 08, 2007, 10:46:52 AM
I think this could be related to your language strings, since your forum is set to use a different language.

But I dont know mush about languages to be honest since I only use English myself.

But its very strange this is not working for u, especially since it is the default template as well.

Title: Re: Users Online Today Mod
Post by: Mayhem30 on January 08, 2007, 04:22:09 PM
I am using SMF 1.1.1

Anyways I can get this mod to show guests who's been online today?

It works great for registered users but it comes up completely blank for guests.

Thanks!
Title: Re: Users Online Today Mod
Post by: Mayhem30 on January 08, 2007, 10:18:05 PM
bump
Title: Re: Users Online Today Mod
Post by: bigmohi on January 11, 2007, 03:07:49 PM
someone help plz to install this mod at other themes, i tried everything but nothing work, plz say which code we replace!!
Title: Re: Users Online Today Mod
Post by: shaka on January 11, 2007, 06:38:20 PM
hi guys i have just installed this mod and my board index has went crazy

www.coversplace.com/newforum   any ideas how to fix this i have uninstalled and deleted the mod
Title: Re: Users Online Today Mod
Post by: watchhorse on January 12, 2007, 07:39:11 AM
I want to put this:
Quote// Users online today

   echo '
   <tr>
      <td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
   </tr><tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         <img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
      </td>
      <td class="windowbg2" width="100%">';

   echo '
         <div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
     echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

   // Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
   if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
      echo '<br />', implode(', ', $context['list_users_online_today']);

   echo '
            <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
            <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
         </div>
      </td>
   </tr>';

on the stats-page so the list is not on the index of the forum but on the stats-page.
It want work now , the list is empty but when i put the code on de index-template i see the members.

What is wrong ... how can i put it on the stats-page so i will see the members???


Btw: sorry when my english is bad.
Title: Re: Users Online Today Mod
Post by: auroramae on January 14, 2007, 11:50:47 AM
I am hoping that someone will be kind enough to tell me how to manually edit the slick_pro graphite theme to show
Users Logged In Today
When I apply the mod to that theme it doesn't apply all of the changes.
It displays 
Users Online
but not
Users Logged In Today

Any help would be greatly appreciated.

aurora
Title: Re: Users Online Today Mod
Post by: Bigguy on January 14, 2007, 02:05:41 PM
This should be the only edit you have to do. In your BoardIndex.template.php find:

</span>
</td>
</tr>';


Before that add:

// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


Title: Re: Users Online Today Mod
Post by: auroramae on January 14, 2007, 02:25:55 PM
QuoteThis should be the only edit you have to do. In your BoardIndex.template.php find:

A thousand thank yous!
Worked like a charm.
Title: Re: Users Online Today Mod
Post by: SvenJTD on January 15, 2007, 12:44:19 PM
Finaly got it working :), but is there a way to make it line the users in alfabetical order ????
Thanks
Title: Re: Users Online Today Mod
Post by: watchhorse on January 16, 2007, 03:55:51 AM
Is there now way to put it in de stats-page.
The list in my forum is too big to put it in the index so i will put it in de stats-page.


Any help would be greatly appreciated.

Thanks
Title: Re: Users Online Today Mod
Post by: thegpg on January 16, 2007, 09:42:03 PM
I installed this mod on my forums (1.1.1) and it doesn't seem to be working.  Currently using the default theme.  Help please?
Title: Re: Users Online Today Mod
Post by: GC on January 16, 2007, 11:50:25 PM
Quote from: auroramae on January 14, 2007, 11:50:47 AM
I am hoping that someone will be kind enough to tell me how to manually edit the slick_pro graphite theme to show
Users Logged In Today
When I apply the mod to that theme it doesn't apply all of the changes.
It displays 
Users Online
but not
Users Logged In Today

Any help would be greatly appreciated.

aurora

How come nobody ever reads the modification file?
Title: Re: Users Online Today Mod
Post by: auroramae on January 17, 2007, 12:53:13 AM
I tried.  I think I am too stupid to understand it.
Title: Re: Users Online Today Mod
Post by: auroramae on January 17, 2007, 12:24:40 PM
If I disable the SP1 style of stats I lose the list of users logged in today.
When I enable the SP1 stats I lose the
stats at the top of the page with welcome newest member.
Is there any way around this.
I want the users logged in today list
without the SP1 stats
Title: Re: Users Online Today Mod
Post by: txleo on January 18, 2007, 02:06:54 AM
I am using the default themes also. Is this what I need to edit, in my case?  Same thing. It is not displaying the users-online-today even though the mod was installed.



Quote from: Bigguy on January 14, 2007, 02:05:41 PM
This should be the only edit you have to do. In your BoardIndex.template.php find:

</span>
</td>
</tr>';


Before that add:

// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';



Title: Re: Users Online Today Mod
Post by: vodkanestum on January 18, 2007, 08:19:01 AM
hi, i'm using smf 1.1.1 on my forum and the theme Dilber Multicolor and i'd like to use the users online today mod on that theme but i don't know how to do it, can someone help me? :/
Title: Re: Users Online Today Mod
Post by: webvision on January 18, 2007, 10:03:30 AM
Nice Mod
Title: Re: Users Online Today Mod
Post by: mohoganybrwn on January 19, 2007, 01:15:20 AM
Hi.  Installed this mod, now I have the following at the top of my forum:

Quote$txt['uot_users_online_today']='Users Logged In Today'; $txt['uot_yesterday']='Yesterday at '; $txt['uot_total']='Total'; $txt['uot_visible']='Visible'; $txt['uot_hidden']='Hidden';


Can anyone tell me how I can remove this please?
Title: Re: Users Online Today Mod
Post by: Croco on January 19, 2007, 01:24:00 AM
Quote from: mohoganybrwn on January 19, 2007, 01:15:20 AM
Hi.  Installed this mod, now I have the following at the top of my forum:

Quote$txt['uot_users_online_today']='Users Logged In Today'; $txt['uot_yesterday']='Yesterday at '; $txt['uot_total']='Total'; $txt['uot_visible']='Visible'; $txt['uot_hidden']='Hidden';


Can anyone tell me how I can remove this please?


read this :
http://www.simplemachines.org/community/index.php?topic=143769.0
Title: Re: Users Online Today Mod
Post by: watchhorse on January 20, 2007, 06:04:09 AM
I try again:

I want to but the list on the stats-page and not on the index-page.
How can i do this???


Please help....
Title: Re: Users Online Today Mod
Post by: xtremecruiser on January 26, 2007, 11:09:07 PM
How about adding the guest count for the day too, just the number like it does for Users Online

Thanks
Title: Re: Users Online Today Mod
Post by: Tick on January 28, 2007, 12:50:42 PM
I recently installed this mod , I am using smf 1.1.1 and the theme classic YaBB SE theme.  I know that you have to modify the boardindex.  templete.  The prob I am having is I have no idea how to do this.  I am a fish out of water here .  I someone could give me a step by step to do this I would appreciate it.  THanks
Title: Re: Users Online Today Mod
Post by: Tick on January 28, 2007, 10:07:18 PM
I finally got it on the page.  Is it supposed to have a users logged on today title above it?  Mine does  not .  If it is supposed to please someone tell me how to add it.   Thanks ahead of time.
Title: Re: Users Online Today Mod
Post by: Tick on January 29, 2007, 05:10:48 PM
Can anybody tell me why the title users logged in today above where it shows users logged in today
Title: Re: Users Online Today Mod
Post by: ludothegreat on February 08, 2007, 02:07:13 AM
Just installed this mod on SMF 1.1.1  using Dilbert MC theme. I am now getting a bunch of code at the top of my Forum. Even after uninstalling the mod it is still there. Here is the code.

$txt['uot_users_online_today']='Users Logged In Today'; $txt['uot_yesterday']='Yesterday at '; $txt['uot_total']='Total'; $txt['uot_visible']='Visible'; $txt['uot_hidden']='Hidden';

I also tried to reinstall the mod thinking maybe something installed wrong and it added a second line with the same exact thing at the top. So now I have two lines of code. Here is the site if you want to check it out for yourself.

http://ludothegreat.com/mallorngardens/forums/

I just want to get rid of the code. Thanks in advance.
Title: Re: Users Online Today Mod
Post by: Sir_Trout on February 13, 2007, 09:34:04 PM
Just installed this mod on SMF 1.1.2  using Dilbert MC theme and it did not work, but it does work on the default theme.  so I did some reading and found the following...

Quote from: Bigguy on January 14, 2007, 02:05:41 PM
This should be the only edit you have to do. In your BoardIndex.template.php find:

</span>
</td>
</tr>';


Before that add:

// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';




:P But I get get this error when I try and install the above code.
The file you tried to save generated the following error:
Parse error: parse error, unexpected '>' in BoardIndex.template.php on line 223

Any ideas?


-ST
Title: Re: Users Online Today Mod
Post by: Bigguy on February 13, 2007, 09:48:42 PM
I am getting the same error and will try to figure this out tonight. When I do I will post something. (if I do)
Title: Re: Users Online Today Mod
Post by: Sir_Trout on February 13, 2007, 09:52:02 PM
One more question, you said to look for this...
                      </span>
      </td>
   </tr>';

Do I look for the first instance of this?  because I see it more then once....  In the Dilbert MC theme any ways.

-ST
Title: Re: Users Online Today Mod
Post by: archiebald on February 14, 2007, 01:52:32 AM
Sorry, I didn't read all 38 pages of this thread.

This mod did not work when attempting to install with the 1.1.2 default theme.
Title: Re: Users Online Today Mod
Post by: Carceri on February 14, 2007, 04:49:50 AM
Quote from: archiebald on February 14, 2007, 01:52:32 AM
Sorry, I didn't read all 38 pages of this thread.

This mod did not work when attempting to install with the 1.1.2 default theme.

Okay, I will look into that. It works if you have the mod applied to 1..1.1 when upgrading to 1.1.2, so I guess the changes required to make it work with 1.1.2 are minimal.

Could you please tell me what files it fails to apply the mod to?
Title: Re: Users Online Today Mod
Post by: archiebald on February 14, 2007, 10:13:39 AM
Surely,

3.    Execute Modification    C:\Inetpub\wwwroot\forum/Themes/default/BoardIndex.template.php    Test failed

All other pre-installation tests are successful
Title: Re: Users Online Today Mod
Post by: Bigguy on February 14, 2007, 12:08:43 PM
Ok I have just installed this and it works. If you install the mod with the error on BoardIndex.template.php you have to put the edit in manually for that file but it's hard to find. Look for this in the BoardIndex.template.php file:

echo $newmembul123 , ' New This Month: ' , $row['month'] , ' ' , $newmembul123 , ' New This Week: ' , $row['week'] , ' ' , $newmembul123 , ' New Today: ' , $row['today'];

After that add this:

  // Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


and it should work for you. Back up first before trying this.
Title: Re: Users Online Today Mod
Post by: archiebald on February 14, 2007, 07:37:48 PM
Many Thanks
Title: Re: Users Online Today Mod
Post by: SaltedWeb on February 15, 2007, 09:54:13 AM
Hi Guys , with so many edits mentioned I am lost as to what to use  :'(

I installed the mod fine on. 1.1.1 ( now 1.1.2 ) I want to use the classic theme
when I switch of course the mod is no longer active.
But is installed.

Do I uninstall and try re-install it?
Or do I edit a PHP file if so what do I edit in?

What do I need to do to make it work in the classic mode?

Thanks you for this Mod I am hopeful to use it on the other Classic Theme.


Cozmo

Title: Re: Users Online Today Mod
Post by: Bigguy on February 15, 2007, 01:29:08 PM
Mods only work on the default theme so if you switch themes you will have to do a bit of editing. The only files that need to be edited seeing as its already installed is any template files it modifies. Obviously BoardIndex.template.php is one of the template files that need to be edited. You can find that edit a couple posts up. For any others you will have to look in the .xml file of the package to see if there are anymore template files to edit. (Not the Package-info.xml file)
Title: Re: Users Online Today Mod
Post by: SaltedWeb on February 15, 2007, 01:48:08 PM
Hi That,
was part of the question there are to may responses and edits described in this post to make heads or tales as to what are the edits and where  do they take place?


Cozmo
Title: Re: Users Online Today Mod
Post by: Bigguy on February 15, 2007, 02:05:54 PM
Stats.template.php
BoardIndex.template.php

Are the only template files. If you have a Stats.template.php in the default theme folder and NOT in the custom theme you are using it should not have to be done. In Stats.template.php find:

<td nowrap="nowrap">', $txt['users_online_today'], ':</td>
<td align="right">', $context['online_today'], '</td>';


And replace with:

<td nowrap="nowrap">', $txt['users_online_today'], ':</td>
<td align="right">', $context['online_today'], '</td>
</tr><tr>
<td nowrap="nowrap">', $txt['uot_users_online_today'], ':</td>
<td align="right">', $context['total_users_online_today'], '</td>';
Title: Re: Users Online Today Mod
Post by: Carceri on February 16, 2007, 02:46:38 PM
Well, BoardIndex.template is unchanged between 1.1.1 and 1.1.2, so there must be something else wrong.

Quote from: archiebald on February 14, 2007, 10:13:39 AM
Surely,

3.    Execute Modification    C:\Inetpub\wwwroot\forum/Themes/default/BoardIndex.template.php    Test failed

All other pre-installation tests are successful
Title: Re: Users Online Today Mod
Post by: Photoshocker on February 21, 2007, 03:24:53 PM
Hi, im using Aa New Damage Theme and i cant get this work.

What modifications should i do to get it work?

Thanks.
Title: Re: Users Online Today Mod
Post by: Inflame on February 21, 2007, 06:10:24 PM
Heya


I was wondering,

is there an option the have a code in a script box from TP to show it to all users online, so I don't need to modify all themes I use with the code's, and everyone can see it right away

Is this an option or just me talking weird?
Title: Re: Users Online Today Mod
Post by: Bigguy on February 23, 2007, 09:47:44 AM
I think code for that could be found at www.tinyprtal.net. I don't think this mod will do in a block.  
Title: Re: Users Online Today Mod
Post by: Grozzy on February 28, 2007, 11:34:24 AM
I accidentally installed this on a customized theme, and it didn't work.
Now I got a text on the top of the page saying:
$txt['uot_users_online_today']='Users Logged In Today'; $txt['uot_yesterday']='Yesterday at '; $txt['uot_total']='Total'; $txt['uot_visible']='Visible'; $txt['uot_hidden']='Hidden';


What can I do to remove it ?
Title: Re: Users Online Today Mod
Post by: Bigguy on February 28, 2007, 04:20:58 PM
In the modifications.english.php file make sure that the ?> is right at the very end of the file and not at the end of that code.
Title: Re: Users Online Today Mod
Post by: Grozzy on February 28, 2007, 05:38:59 PM
I want to remove it, I don't want the mod, just want to remove it.
Title: Re: Users Online Today Mod
Post by: Bigguy on February 28, 2007, 07:00:28 PM
In modifications.english.php search for these lines and take them out. ;)

$txt['uot_users_online_today']='Users Logged In Today'; $txt['uot_yesterday']='Yesterday at '; $txt['uot_total']='Total'; $txt['uot_visible']='Visible'; $txt['uot_hidden']='Hidden';
Title: Re: Users Online Today Mod
Post by: Grozzy on February 28, 2007, 07:06:54 PM
And where do I find modifications.english.php ?
Title: Re: Users Online Today Mod
Post by: Bigguy on February 28, 2007, 07:17:50 PM
In the langauge folder of the theme you are using. Or in the default theme's language folder.
Title: Re: Users Online Today Mod
Post by: Grozzy on February 28, 2007, 07:31:41 PM
How do I open PHP files ?

And I don't manually add them to the forum, I upload and install the ZIP file.
Title: Re: Users Online Today Mod
Post by: Bigguy on February 28, 2007, 10:51:55 PM
Download them to your desktop and open them with a php editor. Something like "Php Designer" although note pad will do. :)
Title: Re: Users Online Today Mod
Post by: Grozzy on March 01, 2007, 07:28:12 AM
How can I download the files from the site AND keep the changes I will make ?  ::)
Title: Re: Users Online Today Mod
Post by: Inflame on March 01, 2007, 10:46:42 AM
Quote from: Grozzy on March 01, 2007, 07:28:12 AM
How can I download the files from the site AND keep the changes I will make ?  ::)

Get into the site with the FTP
Find the file, and drag them to your desktop,
Open it with Note Path, and remove the lines given above.

Then save the file again, and drag the file back to your FTP folder,

It should be fixed now,

If you don't know how to access your FTP, contact the person or company which give syou the webhosting, and ask them for the log-in and any help you need
Title: Re: Users Online Today Mod
Post by: veldfire on March 01, 2007, 04:21:24 PM
Is there a way to hide the list from guests ?
Title: Re: Users Online Today Mod
Post by: smoothlab on March 07, 2007, 09:47:04 AM
i've seen this asked but don't think a definitive answer was ever posted.

is there a fix for this mod when running SMF 1.1.2 and the DilberMC theme?

thanks for your help
Title: Re: Users Online Today Mod
Post by: symon on March 07, 2007, 07:41:45 PM
Nowhere to edit the boardindex.template in Babylon :(

But it still shows the onlines wrong. I had nearly 100 of my members online today. Yet it shows 24! It seems to be the number that was online at the same time...not the whole day. Does anyone know why SMF does this?

Does anyone know a way to show a days total?

Ta :)
Title: Re: Users Online Today Mod
Post by: smoothlab on March 08, 2007, 02:08:49 PM
bump

dilber mc please???
Title: Re: Users Online Today Mod
Post by: symon on March 08, 2007, 05:46:16 PM
The Online Today stat in SMF is absolutely stupid. It's the most online at once...not over the whole day. Today mine says 27...when clearly I have had 300 people online.

It's showing me up.

How do I get rid of it?

Edit* Retracting stupid remark as I found how to use this mod in Babylon and it works sweeeet. After altering the previous language files to make the default stats clearer this mod shows the daily totals :D

See later post to how to install in Babylon
Title: Re: Users Online Today Mod
Post by: Tick on March 11, 2007, 12:40:59 AM
I got this mod installed fine. The only problem I am having is the words Users Logged In today does not show up.  I am using smf 1.1.2  .  Tiny portal is the only other mod I have installed.


It also doesnt say   (visible  ,  hidden)  just the numbers



Edit:  never mind I got it .
Title: Re: Users Online Today Mod
Post by: smoothlab on March 11, 2007, 09:51:56 AM
anyone get it working with DilberMC theme?
Title: Re: Users Online Today Mod
Post by: Tick on March 11, 2007, 10:47:08 AM
yes this is the theme I am using.  It works fine for me.  What kind of problems are you having?
Title: Re: Users Online Today Mod
Post by: smoothlab on March 11, 2007, 12:36:08 PM
it just doesn't appear.  it installs fine, but nothing appears in the forum index.
Title: Re: Users Online Today Mod
Post by: Tick on March 11, 2007, 01:18:19 PM
did you modify your board index template php.   if you didnt  first make a backup copy (incase you mess up)
go to you dilber mc board index template .php   find this code

', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';


add after it.
// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';
Title: Re: Users Online Today Mod
Post by: smoothlab on March 11, 2007, 02:31:54 PM
worked like a charm.  Thanks so much
Title: Re: Users Online Today Mod
Post by: Tick on March 11, 2007, 02:37:36 PM
sure thing.  I too am just learning how to really do things  .  One helpfull tip for you is do what I do.  I have spent many many hours on this site just reading and learning. I also have a test forum that I can learn on.  I try to take what I read here and appy it there.  It is real helpful.  Glad I could help you.
Title: Re: Users Online Today Mod
Post by: Peter_Roehlen on March 12, 2007, 12:14:16 AM
I installed this mod under 1.1.2 and it didn't work. I get the following line of code now at the top of every page in my forum:

$txt['uot_users_online_today']='Users Logged In Today'; $txt['uot_yesterday']='Yesterday at '; $txt['uot_total']='Total'; $txt['uot_visible']='Visible'; $txt['uot_hidden']='Hidden';

What's worst, is that the uninstall doesn't uninstall it.  Anyone got any tips on how I can get rid of this mod?

Title: Re: Users Online Today Mod
Post by: Bigguy on March 12, 2007, 12:17:44 AM
Those lines are from the modifications.english.php file and the problem probably is that the
?> is not at the end of the file or those lines are after the ?> open up that file and make sure that ?> is at the very end of the file. That should get rid of the text.

If it won't uninstall then you will have to manually remove the code. All the edits can be found in the .xml file of the package. (Not the package-info.xml the other .xml file)
Title: Re: Users Online Today Mod
Post by: Peter_Roehlen on March 12, 2007, 12:26:53 AM
Okay, thanks BG, I'll give it a shot.
Title: Re: Users Online Today Mod
Post by: veldfire on March 12, 2007, 02:29:21 PM
Quote from: veldfire on March 01, 2007, 04:21:24 PM
Is there a way to hide the list from guests ?
????
Title: Re: Users Online Today Mod
Post by: symon on March 12, 2007, 04:57:26 PM
Can anyone please answer me a few questions straight pweeeeeeze :)

1: I'm used to manually installing mods but there is nowhere to edit the boardindex.template in Babylon. This is surprising as the Babylon theme was the old default theme.

2: Will this show (including guests) the number of visitors online in 24 hours? NOT the most online together which they all seem to do?

Ta for your help in advance...

:)
Title: Re: Users Online Today Mod
Post by: symon on March 12, 2007, 07:00:38 PM
Added it to Babylon

Ok...I found this myself as it's not greatly difficult. ;) But rather than go "It's ok...I solved it" I thought I'd show you what I did ;)

I found this code in babylon/Boardindex.template.php:

// "Users online" - in order of activity.
echo '
<tr>
<td class="catbg" colspan="2">', $txt[158], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
', $context['show_who'] ? '<a href="' . $scripturl . '?action=who">' : '', '<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], '" border="0" />', $context['show_who'] ? '</a>' : '', '
</td>
<td class="windowbg2" width="100%">';

if ($context['show_who'])
echo '
<a href="', $scripturl, '?action=who">';

echo $context['num_guests'], ' ', $context['num_guests'] == 1 ? $txt['guest'] : $txt['guests'], ', ' . $context['num_users_online'], ' ', $context['num_users_online'] == 1 ? $txt['user'] : $txt['users'];


// Handle hidden users and buddies.
if (!empty($context['num_users_hidden']) || ($context['show_buddies'] && !empty($context['show_buddies'])))
{
echo ' (';

// Show the number of buddies online?
if ($context['show_buddies'])
echo $context['num_buddies'], ' ', $context['num_buddies'] == 1 ? $txt['buddy'] : $txt['buddies'];

// How about hidden users?
if (!empty($context['num_users_hidden']))
echo $context['show_buddies'] ? ', ' : '', $context['num_users_hidden'] . ' ' . $txt['hidden'];

echo ')';
}

if ($context['show_who'])
echo '</a>';

echo '
<div class="smalltext">';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online']))
echo '
', $txt[140], ':<br />', implode(', ', $context['list_users_online']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>


And added after it:



<tr>
<td class="windowbg" width="20" valign="middle" align="center">
</td>
<td class="windowbg2" width="100%">
<div class="smalltext">', $txt['most_online_today'], ': <b>', $modSettings['mostOnlineToday'], '</b>.
', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</div>
</td>
</tr>';

// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


In the added code I changed:

<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>

To:

<td class="catbg" colspan="2">', $txt['uot_users_online_today'], '</td>

Does this look ok to you experienced coders? It works great now :)
Title: Re: Users Online Today Mod
Post by: symon on March 12, 2007, 07:13:34 PM
This works fantastically now.

But does anyone know how to make it show the 'total online today' number include guests also?

The reason I ask this is because I get about 2000 visitors a day and the amount of members online in a day is much less.

Is it possible? :)
Title: Re: Users Online Today Mod
Post by: symon on March 12, 2007, 08:37:38 PM
OK, to add guests to the stats at the foot of the page I have this so far...

Bearing in mind $context['num_total_guests'] is not the right function, nor real (I'm hoping you guys in the know will help), I've added it in the right places using $context[''num_guests''] in the produced site so it actually runs. But obviously $context[''num_guests''] just gives the guests on at that time.

So this is cosmetic until anyone can help :)

Modifications.English.php add to the end:

$txt['uot_guests']='Guests';

Add to BoardIndex.php:

$context['num_users_online_today'] = count($context['users_online_today']);
if (!$user_info['is_admin'])
{
$context['num_users_online_today'] = $context['num_users_online_today'] + $context['num_hidden_users_online_today'] + $context[''num_total_guests''];
}


Add to BoardIndex.template.php:

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_guests'], ': ', $context['num_total_guests'], ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';


This all displays fine but I'm out of my depth for writing the fetch from database stuff and writing a real $context['num_total_guests'] function that returns the whole days guest numbers.

Does that make sense? Can anyone help with this?

:)
Title: Re: Users Online Today Mod
Post by: symon on March 15, 2007, 05:36:02 PM
Is there just a function and a DB table needed to make this work?

It would make this mod complete.  I'm suprised it's not considered :)
Title: Re: Users Online Today Mod
Post by: Vanterax on March 16, 2007, 08:13:13 AM
Quick question about the mod.

I got it installed and working.  It's beautiful!  However, it seems to build the list of user logged on today according to the server time.  I don't know where my server is located physically, but the list of user who logged on today starts at 8am EST for me.  So here's my question:

Is there a way for the list of user to be built according to my midnight and not the server's?  In other words, using the user's time offset?
Title: Re: Users Online Today Mod
Post by: Vanterax on March 16, 2007, 08:18:06 AM
Hmmm...  Maybe I should've read your code before making this request...

$midnight = mktime(0, 0, 0, $date['mon'], $date['mday'], $date['year']) - ($modSettings['time_offset'] * 3600);



You seem to be already doing this.  However, it doesn't seem to work on my end.  I hate dealing with time. :)

EDIT:  I removed the "- ($modSettings['time_offset'] * 3600);" part and now it's showing up the list fine.  It's very odd.

EDIT2: I think I know what was wrong.  The forum itself had an overall time offset for all users and the mod doesn't take that into account.  Unsetting it resolved it.  :)
Title: Re: Users Online Today Mod
Post by: farzad on March 16, 2007, 10:06:57 AM
any thought to add logged in users AND guest counts to this mod instead of just users that have logged in?

Title: Re: Users Online Today Mod
Post by: symon on March 19, 2007, 04:53:22 PM
I'll have a go if someone helps me write the correct DB table.

Or maybe the creator of this mod doesn't want it meddled with ;)
Title: Re: Users Online Today Mod
Post by: symon on March 22, 2007, 03:00:36 PM
Is offering to help make something better a bad thing on the SMF forum?

Just it's gone very quiet...even by busy standards :D
Title: Re: Users Online Today Mod
Post by: farzad on March 22, 2007, 03:04:23 PM
i have no skills to help, however  i doubt the open source nature of SMF and the mod would not prohibit you from enhancing or experimenting with it.
Title: Re: Users Online Today Mod
Post by: symon on March 22, 2007, 03:14:31 PM
Well I wrote the display side of things in previous posts but I too haven't the skills to write the function and DB table to make it work LOL.

It would make this mod complete rather than a bit open-ended and be an impressive stat to have on the sites.
Title: Re: Users Online Today Mod
Post by: symon on March 23, 2007, 05:06:23 PM
At what point is the uot_yesterday part used? It doesn't display anywhere and would be handy :)
Title: Re: Users Online Today Mod
Post by: Photoshocker on March 23, 2007, 05:54:54 PM
Edit. Found it.
Title: Re: Users Online Today Mod
Post by: alo on March 24, 2007, 05:19:06 AM
Quote from: symon on March 12, 2007, 07:00:38 PM
Added it to Babylon

Ok...I found this myself as it's not greatly difficult. ;) But rather than go "It's ok...I solved it" I thought I'd show you what I did ;)

I found this code in babylon/Boardindex.template.php:

// "Users online" - in order of activity.
echo '
<tr>
<td class="catbg" colspan="2">', $txt[158], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
', $context['show_who'] ? '<a href="' . $scripturl . '?action=who">' : '', '<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], '" border="0" />', $context['show_who'] ? '</a>' : '', '
</td>
<td class="windowbg2" width="100%">';

if ($context['show_who'])
echo '
<a href="', $scripturl, '?action=who">';

echo $context['num_guests'], ' ', $context['num_guests'] == 1 ? $txt['guest'] : $txt['guests'], ', ' . $context['num_users_online'], ' ', $context['num_users_online'] == 1 ? $txt['user'] : $txt['users'];


// Handle hidden users and buddies.
if (!empty($context['num_users_hidden']) || ($context['show_buddies'] && !empty($context['show_buddies'])))
{
echo ' (';

// Show the number of buddies online?
if ($context['show_buddies'])
echo $context['num_buddies'], ' ', $context['num_buddies'] == 1 ? $txt['buddy'] : $txt['buddies'];

// How about hidden users?
if (!empty($context['num_users_hidden']))
echo $context['show_buddies'] ? ', ' : '', $context['num_users_hidden'] . ' ' . $txt['hidden'];

echo ')';
}

if ($context['show_who'])
echo '</a>';

echo '
<div class="smalltext">';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online']))
echo '
', $txt[140], ':<br />', implode(', ', $context['list_users_online']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>


And added after it:



<tr>
<td class="windowbg" width="20" valign="middle" align="center">
</td>
<td class="windowbg2" width="100%">
<div class="smalltext">', $txt['most_online_today'], ': <b>', $modSettings['mostOnlineToday'], '</b>.
', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</div>
</td>
</tr>';

// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


In the added code I changed:

<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>

To:

<td class="catbg" colspan="2">', $txt['uot_users_online_today'], '</td>

Does this look ok to you experienced coders? It works great now :)
how to show names of users online to guests? it shown number of user online only
Title: Re: Users Online Today Mod
Post by: symon on March 24, 2007, 11:48:02 AM
Quote from: alo on March 24, 2007, 05:19:06 AM
how to show names of users online to guests? it shown number of user online only

Hey,

Did you add all of the code to all of the files including the Boardindex.template.php in the default theme folder as well as the Babylon theme? The code I've done is ONLY for the babylon Boardindex.template.php. The code for the default theme is with the package. :)

I'll try and help as much as I can but my expertise is limited (it's not even expertise! lol)
Title: Re: Users Online Today Mod
Post by: alo on March 24, 2007, 06:01:34 PM
Quote from: symon on March 24, 2007, 11:48:02 AM
Quote from: alo on March 24, 2007, 05:19:06 AM
how to show names of users online to guests? it shown number of user online only

Hey,

Did you add all of the code to all of the files including the Boardindex.template.php in the default theme folder as well as the Babylon theme? The code I've done is ONLY for the babylon Boardindex.template.php. The code for the default theme is with the package. :)

I'll try and help as much as I can but my expertise is limited (it's not even expertise! lol)
i'm using another theme...not the babylon theme
Title: Re: Users Online Today Mod
Post by: symon on March 24, 2007, 07:21:50 PM
That code tweak was for it to work in the babylon theme :(
Title: Re: Users Online Today Mod
Post by: alo on March 26, 2007, 08:04:30 PM
Quote from: symon on March 24, 2007, 07:21:50 PM
That code tweak was for it to work in the babylon theme :(
i'm not good at php, can u help me?
Title: Re: Users Online Today Mod
Post by: mgaidia on March 27, 2007, 04:00:10 PM
how can i install this on SAF MC theme?
Title: Re: Users Online Today Mod
Post by: symon on March 27, 2007, 04:13:14 PM
Quote from: alo on March 26, 2007, 08:04:30 PM
i'm not good at php, can u help me?

I'm afraid I can't. I only know the Babylon theme as like you I'm not too good with PHP. Hopefully one of the creators here will be able to help with your theme but they seem to have all gone :(

If you're using Babylon I'll try to help ;)
Title: Re: Users Online Today Mod
Post by: Bigguy on March 27, 2007, 06:16:12 PM
The instructions are in the install.xml file of the zip package of this mod.Unpack the mod and open the zip andyou will see it.  
Title: Re: Users Online Today Mod
Post by: symon on March 27, 2007, 07:55:00 PM
This is true but they are only for the default theme.

I've posted the change needed for the Babylon theme :D

I suspect other themes may need a little bit digging.

Bigguy...would you know how to complete the function and do the database bits so this mod showed accumulative guests also? I posted a few pages back that I had it ready to go and posted the code. I just need help with the DB and function. I think people want it to enhance this great mod :)
Title: Re: Users Online Today Mod
Post by: Bigguy on March 27, 2007, 07:59:10 PM
I am really no good with databases. maybe another team member will see this and step in. You should ask the author first however if it is ok to modify his modification package.
Title: Re: Users Online Today Mod
Post by: symon on March 27, 2007, 08:01:59 PM
I never modified it...I just posted how to get it to work in a theme other than default. Surely that's ok?

Hope so :)
Title: Re: Users Online Today Mod
Post by: Bigguy on March 27, 2007, 08:10:05 PM
Yes it is ok. I thought you wanted to do bd changes thats all, my mistake if I am wrong. :)
Title: Re: Users Online Today Mod
Post by: alo on March 27, 2007, 09:49:36 PM
Quote from: alo on March 26, 2007, 08:04:30 PM
Quote from: symon on March 24, 2007, 07:21:50 PM
That code tweak was for it to work in the babylon theme :(
i'm not good at php, can u help me?
i need that work on another theme but thank you!
Title: Re: Users Online Today Mod
Post by: steve51184 on March 28, 2007, 06:01:37 AM
how do i install this on smf 1.1.2 with the default theme?
Title: Re: Users Online Today Mod
Post by: symon on March 28, 2007, 11:11:41 AM
Quote from: Bigguy on March 27, 2007, 08:10:05 PM
Yes it is ok. I thought you wanted to do bd changes thats all, my mistake if I am wrong. :)

Ah..sorry..yeh...the adding guests also?

Yeh...that would be altering it but is that not what a mod maker does to the original code?

Do we need certain permission to make mods? Or is the code open source but mods are not?

Cheers for any info...I know you're busy here :)
Title: Re: Users Online Today Mod
Post by: Bigguy on March 28, 2007, 04:39:09 PM
You can alter the code of SMF anyway you want really but you should always ask the mod authors permission if you are going to make changes to his mod and release what you do to the public. If it is only for personal then you can make changes to it.
Title: Re: Users Online Today Mod
Post by: symon on March 28, 2007, 04:56:24 PM
That makes sense :)

Love the avatar BTW. :D
Title: Re: Users Online Today Mod
Post by: Bigguy on March 28, 2007, 05:54:12 PM
Thanks, lol. :)
Title: Re: Users Online Today Mod
Post by: Jessondair on March 30, 2007, 03:58:56 PM
I regret to say I didn't read all 43 pages of this thread, so if my question is already answered here, I apologize.  Here's what I'd like to see this mod do...

First, I'd like it visible ONLY to admin and moderators.

Then, I'd like it to show me the membernames of those who've logged in, and the IP addresses of guests who've just lurked on the forum.

Is this possible?  I'm afraid I don't have the skills to modify this on my own and make it happen.  :P
Title: Re: Users Online Today Mod
Post by: edi67 on April 02, 2007, 01:59:14 PM
One simple question, i have this mod installed and all work perfectly with smf 1.1.1 but is possible show the list of users online today in Alphabetic Order?? i see the list in casual order and will be more clean have list in alphabetic order

thx  
Title: Re: Users Online Today Mod
Post by: klra on April 03, 2007, 12:59:12 PM
QuoteOne simple question, i have this mod installed and all work perfectly with smf 1.1.1 but is possible show the list of users online today in Alphabetic Order?? i see the list in casual order and will be more clean have list in alphabetic order

I too would like to know how to do this.

Great Mod BTW!

I tried this (SMF ver 1.1.2), still not alphabatizing the list.

link to thread discussion - http://www.simplemachines.org/community/index.php?topic=55513.msg616919#msg616919

Quote
           Re: Users Online Today Mod
« Reply #375 on: June 19, 2006, 10:11:46 AM »   Quote

thanks ceceri. I am still using 1.3.0 (afraid of betas..)...
Anyway, I found a way around the issue I mentioned above. All credits go to Ştefan Tălpălaru, actually.
To show Users online today in alphabetical order rather than login time, you have to do some minor modifications in the BoardIndex.php file (Sources folder), as follows:
Delete "$row['lastLogin'] . " from here

Code:
$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
         'id' => $row['ID_MEMBER'],
         'username' => $row['memberName'],
         'name' => $row['realName'],
         'group' => $row['ID_GROUP'],
         'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
         'link' => $link,
         'is_buddy' => $is_buddy,
         'hidden' => empty($row['showOnline']),
      );

      $context['list_users_online_today'][$row['lastLogin'] . $row['memberName']] = (empty($row['showOnline']) && allowedTo('moderate_forum')) ? '<i>' . $link . '</i>' : $link;

so it will look like

Code:
$context['users_online_today'][$row['memberName']] = array(
         'id' => $row['ID_MEMBER'],
         'username' => $row['memberName'],
         'name' => $row['realName'],
         'group' => $row['ID_GROUP'],
         'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
         'link' => $link,
         'is_buddy' => $is_buddy,
         'hidden' => empty($row['showOnline']),
      );

      $context['list_users_online_today'][$row['memberName']] = (empty($row['showOnline']) && allowedTo('moderate_forum')) ? '<i>' . $link . '</i>' : $link;

and change "krsort" with "ksort"
Code:
  mysql_free_result($result);

   krsort($context['users_online_today']);
   krsort($context['list_users_online_today']);

Remeber, in ASCII capital letters come before small letters (I didn't know..), so all usernames starting with a capital letter will come first.
This works great if  you want your users to be able to see who was online today (regardless hidden/unhidden), without figuring out who's online at the moment
Title: Re: Users Online Today Mod
Post by: ArkServer on April 04, 2007, 07:12:56 PM
Not sure if its asked before but is it possible to show the last _REAL_ 24 hour user online instead of resetting at 0.00AM?
Title: Re: Users Online Today Mod
Post by: Tucker2007 on April 05, 2007, 11:36:56 PM
Open BoardIndex.php

After:    
// Set the latest member.
$context['latest_member'] = &$context['common_stats']['latest_member'];


Add:
$date = strftime('%Y%m%d', forum_time(false));

// Members online so far today.
$result = db_query("
SELECT mostOn
FROM {$db_prefix}log_activity
WHERE date = $date
LIMIT 1", __FILE__, __LINE__);
list ($context['online_today']) = mysql_fetch_row($result);
mysql_free_result($result);

$context['online_today'] = (int) $context['online_today'];

// Total members online today
$date = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $date['mon'], $date['mday'], $date['year']) - ($modSettings['time_offset'] * 3600);
$result = db_query("
SELECT
COUNT(*)
FROM {$db_prefix}members
WHERE lastLogin >= $midnight", __FILE__, __LINE__);
list ($context['total_users_online_today']) = mysql_fetch_row($result);


Open BoardIndex.template

Replace

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';


With

  echo $txt['uot_total'], ': <b>', $context['online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (Members: ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ' , Guests: ', ($context['online_today'] - $context['total_users_online_today']), ')';


This will I hope, I havnt 100% tested however it seems to be working so far. Anyways it will show the number of guests on the forum today, I beleive this is what people wanted, well its what I wanted Example:
Total: 3 (Members: 2, Hidden: 0 , Guests: 1)

Anyways I hope this will keep synmon quiet now hehe, He seems to have been wanting this alot. First post and i've posted something useful  :D (I hope)

Enjoy  ;D

(Sorry if im not very descriptive its 4:30am and I have been looking at code for 5 hours, it messes with your head lol, I feel like a vulcan will all this logic   ::))

Edit: Ok i dont think this works because it only records 1 guest... Bugger :( Well hopefully somone can find this usefull.


Edit2: Ok actually, It seems it is working however logs every 15 minutes which is set by board so I have lowered to refresh every 5 mins, Hey I think I have solved it :D
Title: Re: Users Online Today Mod
Post by: SA™ on April 06, 2007, 02:21:23 AM
hi i installed this mod on the default theme but i cant see any changes is there any where in paticular i should be lookin or has any one got a demo and i got this Execute Modification ./Sources/BoardIndex.php Test successful
2. Execute Modification ./Sources/Stats.php Test successful
3. Execute Modification ./Themes/default/BoardIndex.template.php Test failed
4. Execute Modification ./Themes/default/Stats.template.php Test successful
5. Execute Modification ./Themes/default/languages/Modifications.english.php Test successful
6. Execute Modification ./Themes/default/languages/Stats.english.php Test successful
as an error could this be why thanks for any help in advance


www.joyrider.web-space.ws/forum (http://www.joyrider.web-space.ws/forum)
Title: Re: Users Online Today Mod
Post by: Tucker2007 on April 06, 2007, 12:29:23 PM
Quote from: wdm2005 on April 06, 2007, 02:21:23 AM
hi i installed this mod on the default theme but i cant see any changes is there any where in paticular i should be lookin or has any one got a demo and i got this Execute Modification ./Sources/BoardIndex.php Test successful
2. Execute Modification ./Sources/Stats.php Test successful
3. Execute Modification ./Themes/default/BoardIndex.template.php Test failed
4. Execute Modification ./Themes/default/Stats.template.php Test successful
5. Execute Modification ./Themes/default/languages/Modifications.english.php Test successful
6. Execute Modification ./Themes/default/languages/Stats.english.php Test successful
as an error could this be why thanks for any help in advance


www.joyrider.web-space.ws/forum (http://www.joyrider.web-space.ws/forum)

Are you talking about my mod to this mod or just the mod itself, If my mod then you install the main mod first then modify the files I said and it will wont although when you uninstall you will get that error because your made your own modifcations so basically uninstall my mod first then uninstall the main mod :)

Also it should display something like this underneith who's online on the main index of the board.

Users Online Today
Total: 10 (Members: 3, Hidden: 0, Guests: 7)
User, User2, User3


I've made template modifcations to mine so it displays differently but you will get something like that under the Who's Online box on main index  :) Well with my mod to the mod, without you will get something like this.

Users Logged In Today
Total: 3 (Members: 3, Hidden: 0)
User, User2, User3


I visited your forum and it looks fine to me its where it is suppose to be  :)

Users Logged In Today
Total: 2


Is what I see, Because im a guest, as a member you will get to see what I mentioned above.
Title: Re: Users Online Today Mod
Post by: symon on April 06, 2007, 04:27:24 PM
Tucker...I'm so glad you're tackling this :)

But I get the following after editing the code:

QuoteTotal: 14 (Members: 96, Hidden: 0 , Guests: -82)

The guest is a negative  number!
Title: Re: Users Online Today Mod
Post by: Tucker2007 on April 06, 2007, 06:23:05 PM
Quote from: symon on April 06, 2007, 04:27:24 PM
Tucker...I'm so glad you're tackling this :)

But I get the following after editing the code:

QuoteTotal: 14 (Members: 96, Hidden: 0 , Guests: -82)

The guest is a negative  number!

Yeah I think I have buggered it up :(  I dont think there is a way really without logging guests no sums can be done with current data :(
Title: Re: Users Online Today Mod
Post by: symon on April 06, 2007, 06:32:52 PM
hehe.

At least you are trying ;)

I'm with ya :D

lol
Title: Re: Users Online Today Mod
Post by: symon on April 06, 2007, 06:57:49 PM
Quote from: Tucker2007 on April 06, 2007, 06:23:05 PM
I dont think there is a way really without logging guests no sums can be done with current data :(

Yeh...I think it would involve a new table in the DB to do that. It would be great though as visitors would look at it and be more impressed.

Nice try though :)
Title: Re: Users Online Today Mod
Post by: Tucker2007 on April 06, 2007, 07:30:43 PM
Dont worry I am still quite skilled at database's, Im going to look at my former phpbb one and see if I can devise a way to add logging of guests  :D

Although please anyone else if you can do this please do  ;)  
Title: Re: Users Online Today Mod
Post by: Shonick on April 10, 2007, 04:59:41 PM
I have this error when I install this mod
(http://i13.tinypic.com/4hrqjy1.jpg)

When I install this mod , It does not have any error,but after I install it. I see this error on the top of my site. above the banner as shown in the picture.Could you help me to fix this.Thanks
Title: Re: Users Online Today Mod
Post by: PixieWAttitude on April 11, 2007, 03:30:45 PM
I get the same thing Viet..and it made my board huge, font wise...

And also this at the bottom

: 1 (: 1, : 0)
Admin
Title: Re: Users Online Today Mod
Post by: Shonick on April 11, 2007, 04:14:35 PM
yeah, the font is become big, But I saw at the bottom of my forum, I think it shows everything correctly.Except those error.

Title: Re: Users Online Today Mod
Post by: AllMassive on April 12, 2007, 06:49:49 PM
I'm trying to install this Mod in my smf 1.1.2-utf8 forum.

I get this message:
Installation Readme
Users Online Today Mod (ver. 1.4.0).

Install Actions
Installations actions for "Users Online Today Mod":
Installing this package will perform the following actions:
Type Action Description
1. Execute Modification ./Sources/BoardIndex.php Test successful
2. Execute Modification ./Sources/Stats.php Test successful
3. Execute Modification ./Themes/default/BoardIndex.template.php Test successful
4. Execute Modification ./Themes/default/Stats.template.php Test successful
5. Execute Modification ./Themes/default/languages/Modifications.english.php File not found
6. Execute Modification ./Themes/default/languages/Stats.english.php File not found


I only have 'Modifications.english-utf8.php' and 'Stats.english-utf8.php'

:'(
Title: Re: Users Online Today Mod
Post by: AllMassive on April 12, 2007, 11:02:28 PM
Well - i've read through the xml and did the Changes manually and BLING - Its working  :-X
Title: Re: Users Online Today Mod
Post by: Jumbobeef on April 16, 2007, 01:52:36 PM
Help!  I have just downloaded 1.1.2 and tried to add this to my default theme.  Everytime I try, I get the error message:

QuoteThe package you are trying to download or install is either corrupt or not compatible with this version of SMF.

I have read back the last ten pages or so of this thread but I can't seem to find the answer.  Can anyone help please?

Thanks in advance.
Title: Re: Users Online Today Mod
Post by: Shadow Queen on April 16, 2007, 02:30:19 PM
This mod work great for me.  Thanks for the awesome mod
Title: Re: Users Online Today Mod
Post by: eLeTe on April 16, 2007, 07:02:37 PM
ok, i tried to read allll 44 pages of this thread and i couldnt really find the answer for my question. Im a Total NOOB when it come with editing the files... i can do some but this one im completely lost on. im running 1.1.2 with the mesh theme. what group of codes do i have to put in and where. anybodys help would be really nice. usually i try not to ask for help and figure things out on my own, but this one there is no chance for me.

Thanks in advance.
Title: Re: Users Online Today Mod
Post by: Shadow Queen on April 16, 2007, 09:04:09 PM
You will have to edit some template files. I was merely suggesting looking at the .xml file to get the edits
Title: Re: Users Online Today Mod
Post by: - danny on April 20, 2007, 08:12:14 PM
This installed fine on the forum, but it doesn't display on the Dilber theme I'm using.

Can someone help?
Title: Re: Users Online Today Mod
Post by: rad1701 on April 21, 2007, 08:21:04 AM
Could someone post again what code to change and what to change it to for this mod to work with other themes?  I've looked through this thread, but the code seems to vary.  I'm using 1.1.2, and the Helios theme by Bloc.  But I think the code changes will be the same for any alternate theme.  Right??
Title: Re: Users Online Today Mod
Post by: Tick on April 21, 2007, 08:46:44 AM
Quote from: a.D on April 20, 2007, 08:12:14 PM
This installed fine on the forum, but it doesn't display on the Dilber theme I'm using.

Can someone help?


I posted this a few pages back.  This is how to make it work with dilber mc.     http://www.simplemachines.org/community/index.php?topic=55513.msg1001561#msg1001561
Title: Re: Users Online Today Mod
Post by: - danny on April 22, 2007, 04:49:08 PM
Quote from: tick on April 21, 2007, 08:46:44 AM
Quote from: a.D on April 20, 2007, 08:12:14 PM
This installed fine on the forum, but it doesn't display on the Dilber theme I'm using.

Can someone help?


I posted this a few pages back.  This is how to make it work with dilber mc.     http://www.simplemachines.org/community/index.php?topic=55513.msg1001561#msg1001561

That was perfect! Thank you!  :D
Title: Re: Users Online Today Mod
Post by: braveboy on April 27, 2007, 03:16:20 AM
any idea how to install it on "Scribbles" theme please help me thanks
Title: Re: Users Online Today Mod
Post by: uni on April 30, 2007, 05:30:30 AM
Quote from: Dud on April 28, 2007, 01:57:44 PM
Help Me...all mine says is   : 2 (: 2, : 0)
Yigal, GPGrieco

No picture no nothing Please Help

Im using 1.12

Same thing. I'm using the default theme and a fresh install.

EDIT: Found it. Open your Modifications.english-utf8.php in the language folder inside your default them and add this:
$txt['uot_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';
Title: Re: Users Online Today Mod
Post by: Sarrene on May 11, 2007, 05:37:27 AM
I appoligise ahead of time for any redundancy I am engaging in right now. I know you have all been asked a LOT on how to make this work on modified/custom themes. Though they are pretty much the more common ones.

I have attempted to try out all the fixes for this. From adding code befor the
</span>
</td>
</tr>';

And another post that said to add code after. Not to mention I have a few instances of this above code in my file. I am so confused now. Nothing new there, eh? :)

I am using a (heavely) modified custom theme, based off of Blocs " Cerberus" Theme. I am not sure what is left from that now, to tell the truth. Befor adding this I am not getting any errors reported. I just cannot get it to work. I have however had an error each time I have tried one of the fixes that was posted. I think its because something in my code is just a bit of kilter from the rest. I presume some form of conflict here.

Any help would be MORE then appreciated.
Attached is the BoardIndex.template.php for my site.

Peace and thank you in advance!
Sarrene'

function template_main()
{
        global $context, $settings, $options, $txt, $scripturl, $modSettings;

        // Show some statistics next to the link tree if SP1 info is off.
        echo '
<table width="100%" cellpadding="3" cellspacing="0">
        <tr>
                <td valign="bottom">', theme_linktree(), '</td>
                <td align="right">';
        if (!$settings['show_sp1_info'])
                echo '
         ', $txt[19], ': ', $context['common_stats']['total_members'], ' &nbsp;&#8226;&nbsp; ', $txt[95], ': ', $context['common_stats']['total_posts'], ' &nbsp;&#8226;&nbsp; ', $txt[64], ': ', $context['common_stats']['total_topics'], '
         ', ($settings['show_latest_member'] ? '<br />' . $txt[201] . ' <b>' . $context['common_stats']['latest_member']['link'] . '</b>' . $txt[581] : '');
        echo '
                </td>
        </tr>
</table>';

        // Show the news fader?  (assuming there are things to show...)
        if ($settings['show_newsfader'] && !empty($context['fader_news_lines']))
        {
                echo '
<div class="tborder" style="margin-bottom: 2ex;">
        <table border="0" width="100%" cellspacing="1" cellpadding="4">
                <tr class="titlebg" align="center">
                        <td>', $txt[102], '</td>
                </tr>
                <tr>
                        <td valign="middle" align="center" height="60">';

                // Prepare all the javascript settings.
                echo '
                                <div id="smfFadeScroller" style="width: 90%; padding: 2px; "><b>', $context['news_lines'][0], '</b></div>
            <script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
                                        // The fading delay (in ms.)
                                        var smfFadeDelay = ', empty($settings['newsfader_time']) ? 5000 : $settings['newsfader_time'], ';
                                        // Fade from... what text color?  To which background color?
                                        var smfFadeFrom = {"r": 250, "g": 250, "b": 250}, smfFadeTo = {"r": 40, "g": 40, "b": 40};
                                        // Surround each item with... anything special?
                                        var smfFadeBefore = "<b>", smfFadeAfter = "</b>";

               var foreColor, backEl, backColor;

               if (typeof(document.getElementById(\'smfFadeScroller\').currentStyle) != "undefined")
               {
                  foreColor = document.getElementById(\'smfFadeScroller\').currentStyle.color.match(/#([\da-f][\da-f])([\da-f][\da-f])([\da-f][\da-f])/);
                  smfFadeFrom = {"r": parseInt(foreColor[1]), "g": parseInt(foreColor[2]), "b": parseInt(foreColor[3])};

                  backEl = document.getElementById(\'smfFadeScroller\');
                  while (backEl.currentStyle.backgroundColor == "transparent" && typeof(backEl.parentNode) != "undefined")
                     backEl = backEl.parentNode;

                  backColor = backEl.currentStyle.backgroundColor.match(/#([\da-f][\da-f])([\da-f][\da-f])([\da-f][\da-f])/);
                  smfFadeTo = {"r": eval("0x" + backColor[1]), "g": eval("0x" + backColor[2]), "b": eval("0x" + backColor[3])};
               }
               else if (typeof(window.opera) == "undefined" && typeof(document.defaultView) != "undefined")
               {
                  foreColor = document.defaultView.getComputedStyle(document.getElementById(\'smfFadeScroller\'), null).color.match(/rgb\((\d+), (\d+), (\d+)\)/);
                  smfFadeFrom = {"r": parseInt(foreColor[1]), "g": parseInt(foreColor[2]), "b": parseInt(foreColor[3])};

                  backEl = document.getElementById(\'smfFadeScroller\');
                  while (document.defaultView.getComputedStyle(backEl, null).backgroundColor == "transparent" && typeof(backEl.parentNode) != "undefined" && typeof(backEl.parentNode.tagName) != "undefined")
                     backEl = backEl.parentNode;

                  backColor = document.defaultView.getComputedStyle(backEl, null).backgroundColor.match(/rgb\((\d+), (\d+), (\d+)\)/);
                  smfFadeTo = {"r": parseInt(backColor[1]), "g": parseInt(backColor[2]), "b": parseInt(backColor[3])};
               }

               // List all the lines of the news for display.
               var smfFadeContent = new Array(
                  "', implode('",
                  "', $context['fader_news_lines']), '"
               );
            // ]]></script>
            <script language="JavaScript" type="text/javascript" src="', $settings['default_theme_url'], '/fader.js"></script>
         </td>
      </tr>
   </table>
</div>';
        }

        /* Each category in categories is made up of:
                id, href, link, name, is_collapsed (is it collapsed?), can_collapse (is it okay if it is?),
                new (is it new?), collapse_href (href to collapse/expand), collapse_image (up/down iamge),
                and boards. (see below.) */
        foreach ($context['categories'] as $category)
        {
                echo '
<div class="tborder"><table border="0" width="100%" cellspacing="0" cellpadding="5">
        <tr>
                <td colspan="4" class="titlebg', $category['new'] ? '2' : '', '" height="18">';

                // If this category even can collapse, show a link to collapse it.
                if ($category['can_collapse'])
                        echo '
                        <a href="', $category['collapse_href'], '">', $category['collapse_image'], '</a>';

                echo '
                        ', $category['link'], '
                </td>
        </tr>';

                // Assuming the category hasn't been collapsed...
                if (!$category['is_collapsed'])
                {
                        /* Each board in each category's boards has:
                                new (is it new?), id, name, description, moderators (see below), link_moderators (just a list.),
                                children (see below.), link_children (easier to use.), children_new (are they new?),
                                topics (# of), posts (# of), link, href, and last_post. (see below.) */
                        foreach ($category['boards'] as $board)
                        {
                                echo '
        <tr>
      <td class="windowbg" width="6%" align="center" valign="top"><a href="', $scripturl, '?action=unread;board=', $board['id'], '.0">';

                                // If the board is new, show a strong indicator.
                                if ($board['new'])
                                        echo '<img src="', $settings['images_url'], '/on.gif" alt="', $txt[333], '" title="', $txt[333], '" border="0" />';
                                // This board doesn't have new posts, but its children do.
                                elseif ($board['children_new'])
                                        echo '<img src="', $settings['images_url'], '/on2.gif" alt="', $txt[333], '" title="', $txt[333], '" border="0" />';
                                // No new posts at all!  The agony!!
                                else
                                        echo '<img src="', $settings['images_url'], '/off.gif" alt="', $txt[334], '" title="', $txt[334], '" border="0" />';

            echo '</a></td>
                <td align="left" class="windowbg2">
                        <b><a href="', $board['href'], '" name="b', $board['id'], '">', $board['name'], '</a></b><br />
                        ', $board['description'];

                                // Show the "Moderators: ".  Each has name, href, link, and id. (but we're gonna use link_moderators.)
                                if (!empty($board['moderators']))
                                        echo '
                        <div style="padding-top: 1px;" class="smalltext"><i>', count($board['moderators']) == 1 ? $txt[298] : $txt[299], ': ', implode(', ', $board['link_moderators']), '</i></div>';

                                // Show the "Child Boards: ". (there's a link_children but we're going to bold the new ones...)
                                if (!empty($board['children']))
                                {
                                        // Sort the links into an array with new boards bold so it can be imploded.
                                        $children = array();
                                        /* Each child in each board's children has:
                                                id, name, description, new (is it new?), topics (#), posts (#), href, link, and last_post. */
                                        foreach ($board['children'] as $child)
                                        {
                                                $child['link'] = '<a href="' . $child['href'] . '" title="' . ($child['new'] ? $txt[333] : $txt[334]) . ' (' . $txt[330] . ': ' . $child['topics'] . ', ' . $txt[21] . ': ' . $child['posts'] . ')">' . $child['name'] . '</a>';
                                                $children[] = $child['new'] ? '<b>' . $child['link'] . '</b>' : $child['link'];
                                        }

                                        echo '
                        <div style="padding-top: 1px;" class="smalltext"><i>', $txt['parent_boards'], ': ', implode(', ', $children), '</i></div>';
                                }

                                // Show some basic information about the number of posts, etc.
                                echo '
                </td>
                <td class="windowbg" valign="middle" align="center" style="width: 12ex;"><span class="smalltext">
                        ', $board['posts'], ' ', $txt[21], ' ', $txt['smf88'], '<br />
                        ', $board['topics'],' ', $txt[330], '
                </span></td>
                <td class="windowbg2" valign="middle" width="22%"><span class="smalltext">';

                                /* The board's and children's 'last_post's have:
                                        time, timestamp (a number that represents the time.), id (of the post), topic (topic id.),
                                        link, href, subject, start (where they should go for the first unread post.),
                                        and member. (which has id, name, link, href, username in it.) */
                                if (!empty($board['last_post']['id']))
                                        echo '
                        ', $txt[22], ' ', $txt[30], ' ', $board['last_post']['time'], '<br />
                        ', $txt['smf88'], ' ', $board['last_post']['link'], ' ', $txt[525], ' ', $board['last_post']['member']['link'];

                                echo '
                </span></td>
        </tr>';
                        }
                }

                echo '
</table></div>
<br />';
        }

        if ($context['user']['is_logged'])
        {
                echo '
<div class="tborder" style="padding: 3px;"><table border="0" width="100%" cellspacing="0" cellpadding="5">
        <tr class="titlebg">
      <td align="', !$context['right_to_left'] ? 'left' : 'right', '" class="smalltext">
                        <img src="' . $settings['images_url'] . '/new_some.gif" alt="" border="0" align="middle" /> ', $txt[333], '
                        <img src="' . $settings['images_url'] . '/new_none.gif" alt="" border="0" align="middle" style="margin-left: 4ex;" /> ', $txt[334], '
                </td>
      <td align="', !$context['right_to_left'] ? 'right' : 'left', '" class="smalltext">';
                // Show the mark all as read button?
                if ($settings['show_mark_read'])
                        echo '
         <a href="', $scripturl, '?action=markasread;sa=all;sesc=' . $context['session_id'] . '">', ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/markread.gif" alt="' . $txt[452] . '" border="0" />' : $txt[452]), '</a>';
                echo '
                </td>
        </tr>
</table></div>';
        }

        // Here's where the "Info Center" starts...
        echo '
<br />
<div class="tborder"><table border="0" width="100%" cellspacing="1" cellpadding="4">
        <tr class="titlebg">
                <td align="center" colspan="2">', $txt[685], '</td>
        </tr>';

        // This is the "Recent Posts" bar.
        if (!empty($settings['number_recent_posts']))
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[214], '</td>
        </tr>
        <tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                        <a href="', $scripturl, '?action=recent">
                                <img src="', $settings['images_url'], '/post/xx.gif" alt="', $txt[214], '" border="0" /></a>
                </td>
                <td class="windowbg2">';

                // Only show one post.
                if ($settings['number_recent_posts'] == 1)
                {
                        // latest_post has link, href, time, subject, short_subject (shortened with...), and topic. (its id.)
                        echo '
                        <b><a href="', $scripturl, '?action=recent">', $txt[214], '</a></b>
                        <div class="smalltext">
                                ', $txt[234], ' &quot;', $context['latest_post']['link'], '&quot; ', $txt[235], ' (', $context['latest_post']['time'], ')<br />
                        </div>';
                }
                // Show lots of posts.
                elseif (!empty($context['latest_posts']))
                {
                        echo '
                        <table width="100%" border="0">';
                        /* Each post in latest_posts has:
                                board (with an id, name, and link.), topic (the topic's id.), poster (with id, name, and link.),
                                subject, short_subject (shortened with...), time, link, and href. */
                        foreach ($context['latest_posts'] as $post)
                                echo '
                                <tr>
                                        <td align="right" valign="top" nowrap="nowrap">[', $post['board']['link'], ']</td>
                                        <td valign="top">', $post['link'], ' ', $txt[525], ' ', $post['poster']['link'], '</td>
                                        <td align="right" valign="top" nowrap="nowrap">', $post['time'], '</td>
                                </tr>';
                        echo '
                        </table>';
                }
                echo '
                </td>
        </tr>';
        }

        // Show information about events, birthdays, and holidays on the calendar.
        if ($context['show_calendar'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $context['calendar_only_today'] ? $txt['calendar47b'] : $txt['calendar47'], '</td>
        </tr><tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                        <a href="', $scripturl, '?action=calendar">
                                <img src="', $settings['images_url'], '/icons/calendar.gif" width="20" alt="', $txt['calendar24'], '" border="0" /></a>
                </td>
                <td class="windowbg2" width="100%">
                        <span class="smalltext">';

                // Holidays like "Christmas", "Chanukah", and "We Love [Unknown] Day" :P.
                if (!empty($context['calendar_holidays']))
                        echo '
                                <span style="color: #', $modSettings['cal_holidaycolor'], ';">', $txt['calendar5'], ' ', implode(', ', $context['calendar_holidays']), '</span><br />';

                // People's birthdays.  Like mine.  And yours, I guess.  Kidding.
                if (!empty($context['calendar_birthdays']))
                {
                        echo '
                                <span style="color: #', $modSettings['cal_bdaycolor'], ';">', $context['calendar_only_today'] ? $txt['calendar3'] : $txt['calendar3b'], '</span> ';
                        /* Each member in calendar_birthdays has:
                                id, name (person), age (if they have one set?), is_last. (last in list?), and is_today (birthday is today?) */
                        foreach ($context['calendar_birthdays'] as $member)
                                echo '
                                <a href="', $scripturl, '?action=profile;u=', $member['id'], '">', $member['is_today'] ? '<b>' : '', $member['name'], $member['is_today'] ? '</b>' : '', isset($member['age']) ? ' (' . $member['age'] . ')' : '', '</a>', $member['is_last'] ? '<br />' : ', ';
                }
                // Events like community get-togethers.
                if (!empty($context['calendar_events']))
                {
                        echo '
                                <span style="color: #', $modSettings['cal_eventcolor'], ';">', $context['calendar_only_today'] ? $txt['calendar4'] : $txt['calendar4b'], '</span> ';
                        /* Each event in calendar_events should have:
                                title, href, is_last, can_edit (are they allowed?), modify_href, and is_today. */
                        foreach ($context['calendar_events'] as $event)
                                echo '
            ', $event['can_edit'] ? '<a href="' . $event['modify_href'] . '" style="color: #FF0000;">*</a> ' : '', $event['href'] == '' ? '' : '<a href="' . $event['href'] . '">', $event['is_today'] ? '<b>' . $event['title'] . '</b>' : $event['title'], $event['href'] == '' ? '' : '</a>', $event['is_last'] ? '<br />' : ', ';

                        // Show a little help text to help them along ;).
                        if ($context['calendar_can_edit'])
                                echo '
                                (<a href="', $scripturl, '?action=helpadmin;help=calendar_how_edit" onclick="return reqWin(this.href);">', $txt['calendar_how_edit'], '</a>)';
                }
                echo '
                        </span>
                </td>
        </tr>';
        }
// Users online today

   echo '
   <tr>
      <td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
   </tr><tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         <img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
      </td>
      <td class="windowbg2" width="100%">';

   echo '
         <div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
     echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

   // Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
   if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
      echo '<br />', implode(', ', $context['list_users_online_today']);

   echo '
            <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
            <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
         </div>
      </td>
   </tr>';

        // Show a member bar.  Not heavily ornate, but functional at least.
        if ($settings['show_member_bar'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[331], '</td>
        </tr>
        <tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         ', $context['show_member_list'] ? '<a href="' . $scripturl . '?action=mlist">' : '', '<img src="', $settings['images_url'], '/icons/members.gif" alt="', $txt[332], '" border="0" />', $context['show_member_list'] ? '</a>' : '', '
      </td>
      <td class="windowbg2" width="100%">
         <b>', $context['show_member_list'] ? '<a href="' . $scripturl . '?action=mlist">' . $txt[332] . '</a>' : $txt[332], '</b>
         <div class="smalltext">', $txt[200], '</div>
      </td>
   </tr>';
        }

        // Show YaBB SP1 style information...
        if ($settings['show_sp1_info'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[645], '</td>
        </tr>
        <tr>
                <td class="windowbg" width="20" valign="middle" align="center">
                        <a href="', $scripturl, '?action=stats">
                                <img src="', $settings['images_url'], '/icons/info.gif" alt="', $txt[645], '" border="0" /></a>
                </td>
                <td class="windowbg2" width="100%">
                        <table border="0" width="90%"><tr>
                                <td class="smalltext">
               <div style="float: ', !$context['right_to_left'] ? 'left' : 'right', '; width: 50%;">', $txt[490], ': <b>', $context['common_stats']['total_topics'], '</b></div>', $txt[489], ': <b>', $context['common_stats']['total_posts'], '</b><br />', !empty($context['latest_post']) ? '
                                        ' . $txt[659] . ': &quot;' . $context['latest_post']['link'] . '&quot;  (' . $context['latest_post']['time'] . ')<br />' : '', '
                                        <a href="', $scripturl, '?action=recent">', $txt[234], '</a>', $context['show_stats'] ? '<br />
                                        <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
                                </td>
                                <td width="32%" class="smalltext" valign="top">
               ', $txt[488], ': <b><a href="', $scripturl, '?action=mlist">', $context['common_stats']['total_members'], '</a></b><br />
               ', $txt[656], ': <b>', $context['common_stats']['latest_member']['link'], '</b><br />';
                // If they are logged in, show their unread message count, etc..
                if ($context['user']['is_logged'])
                        echo '
                                        ', $txt['smf199'], ': <b><a href="', $scripturl, '?action=pm">', $context['user']['messages'], '</a></b> ', $txt['newmessages3'], ': <b><a href="', $scripturl, '?action=pm">', $context['user']['unread_messages'], '</a></b>';
                echo '
                                </td>
                        </tr></table>
                </td>
        </tr>';
        }

        // "Users online" - in order of activity.
        echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[158], '</td>
   </tr><tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         ', $context['show_who'] ? '<a href="' . $scripturl . '?action=who">' : '', '<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], '" border="0" />', $context['show_who'] ? '</a>' : '', '
      </td>
      <td class="windowbg2" width="100%">';

   if ($context['show_who'])
      echo '
         <a href="', $scripturl, '?action=who">';

   echo $context['num_guests'], ' ', $context['num_guests'] == 1 ? $txt['guest'] : $txt['guests'], ', ' . $context['num_users_online'], ' ', $context['num_users_online'] == 1 ? $txt['user'] : $txt['users'];

   // Handle hidden users and buddies.
   if (!empty($context['num_users_hidden']) || ($context['show_buddies'] && !empty($context['show_buddies'])))
   {
      echo ' (';

      // Show the number of buddies online?
      if ($context['show_buddies'])
         echo $context['num_buddies'], ' ', $context['num_buddies'] == 1 ? $txt['buddy'] : $txt['buddies'];

      // How about hidden users?
      if (!empty($context['num_users_hidden']))
         echo $context['show_buddies'] ? ', ' : '', $context['num_users_hidden'] . ' ' . $txt['hidden'];

      echo ')';
   }

   if ($context['show_who'])
      echo '</a>';

   echo '
         <div class="smalltext">';

        // Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
        if (!empty($context['users_online']))
                echo '
                                ', $txt[140], ':<br />', implode(', ', $context['list_users_online']);

        echo '
                                <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
                                <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
         </div>
                </td>
        </tr>';

        // If they are logged in, but SP1 style information is off... show a personal message bar.
        if ($context['user']['is_logged'] && !$settings['show_sp1_info'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[159], '</td>
        </tr><tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         ', $context['allow_pm'] ? '<a href="' . $scripturl . '?action=pm">' : '', '<img src="', $settings['images_url'], '/message_sm.gif" alt="', $txt[159], '" border="0" />', $context['allow_pm'] ? '</a>' : '', '
      </td>
                <td class="windowbg2" valign="top">
                        <b><a href="', $scripturl, '?action=pm">', $txt[159], '</a></b>
                        <div class="smalltext">
                                ', $txt[660], ' ', $context['user']['messages'], ' ', $context['user']['messages'] == 1 ? $txt[471] : $txt[153], '.... ', $txt[661], ' <a href="', $scripturl, '?action=pm">', $txt[662], '</a> ', $txt[663], '
                        </div>
                </td>
        </tr>';
        }

        // Show the login bar. (it's only true if they are logged out anyway.)
        if ($context['show_login_bar'])
        {
                echo '
        <tr>
                <td class="catbg" colspan="2">', $txt[34], ' <a href="', $scripturl, '?action=reminder" class="smalltext">(' . $txt[315] . ')</a></td>
        </tr>
        <tr>
                <td class="windowbg" width="20" align="center">
                        <a href="', $scripturl, '?action=login">
                                <img src="', $settings['images_url'], '/icons/login.gif" alt="', $txt[34], '" border="0" /></a>
                </td>
                <td class="windowbg2" valign="middle">
                        <form action="', $scripturl, '?action=login2" method="post" style="margin: 0;">
                                <table border="0" cellpadding="2" cellspacing="0" align="center" width="100%"><tr>
                                        <td valign="middle" align="left">
                                                <label for="user"><b>', $txt[35], ':</b><br /><input type="text" name="user" id="user" size="15" /></label>
                                        </td>
                                        <td valign="middle" align="left">
                                                <label for="passwrd"><b>', $txt[36], ':</b><br /><input type="password" name="passwrd" id="passwrd" size="15" /></label>
                                        </td>
                                        <td valign="middle" align="left">
                                                <label for="cookielength"><b>', $txt[497], ':</b><br /><input type="text" name="cookielength" id="cookielength" size="4" maxlength="4" value="', $modSettings['cookieTime'], '" /></label>
                                        </td>
                                        <td valign="middle" align="left">
                                                <label for="cookieneverexp"><b>', $txt[508], ':</b><br /><input type="checkbox" name="cookieneverexp" id="cookieneverexp" checked="checked" class="check" /></label>
                                        </td>
                                        <td valign="middle" align="left">
                                                <input type="submit" value="', $txt[34], '" />
                                        </td>
                                </tr></table>
                        </form>
                </td>
        </tr>';
        }

        echo '
</table></div>';
}

?>
Title: Re: Users Online Today Mod
Post by: 1MileCrash on May 12, 2007, 08:18:21 PM
any chance we can get an SSI function for this?
Title: Re: Users Online Today Mod
Post by: Joshsux on May 14, 2007, 10:14:46 AM
when i go to install it on my Powered by SMF 1.1.2 i get this:

Error in Package Installation
At least one error was encountered during a test installation of this package. It is strongly recommended that you do not continue with installation unless you know what you are doing, and have made a backup very recently. This error may be caused by a conflict between the package you're trying to install and another package you have already installed, an error in the package, a package which requires another package that you don't have installed yet, or a package designed for another version of SMF.

I ain't going continue with the install till i know how to fix this, thanks guys.
Title: Re: Users Online Today Mod
Post by: alo on May 14, 2007, 09:15:02 PM
anyone can help me to make the user online list appeared to guests? it's shown to members only....only the number is shown to guests.
Thanks so much!
Title: Re: Users Online Today Mod
Post by: symon on May 16, 2007, 08:50:17 AM
Has anyone also worked out how to log guests yet? Tucker? ;) hehe

It would make the stats look far more impressive. Afterall, this mod is supposed to be a way to convince visitors it's an active forum :)
Title: Re: Users Online Today Mod
Post by: symon on May 17, 2007, 07:53:19 PM
My forum says a maximum of 23 visited today. But a total of 2350 visited.

How much to have someone sort out the guest logging? SMF is currently the only forum that can't do it...yet. And it's the best!

Pleeeeeeeeeeeeeeeease  :D lol
Title: Re: Users Online Today Mod
Post by: edi67 on May 18, 2007, 06:50:54 PM
Quote from: edi67 on April 02, 2007, 01:59:14 PM
One simple question, i have this mod installed and all work perfectly with smf 1.1.1 but is possible show the list of users online today in Alphabetic Order?? i see the list in casual order and will be more clean have list in alphabetic order

thx &nbsp;


anyone have the solution ? i tried everything posted here but with not result.  :(
Title: Re: Users Online Today Mod
Post by: icman on May 20, 2007, 03:00:00 PM
thank i like it ..
Title: Re: Users Online Today Mod
Post by: trackman on May 24, 2007, 05:56:30 PM
my Users Logged In Today box is currently showing on my custom theme, but it isn't displaying the members names that have been online today

u/n = test
p/w = test 1

http://cdcoverhideout.com/forum

Any help :D
Title: Re: Users Online Today Mod
Post by: dirtylaundry on May 27, 2007, 12:22:32 PM
can some on please tell me how to fix it on a custom theme i cant figure it out

i use aa damage
Title: Re: Users Online Today Mod
Post by: CHwebby on May 27, 2007, 06:52:07 PM
Quote from: braveboy on April 27, 2007, 03:16:20 AM
any idea how to install it on "Scribbles" theme please help me thanks

I'm trying to figure this out also
Title: Re: Users Online Today Mod
Post by: LunyMarcus on May 28, 2007, 07:54:29 PM
Just recently modified the who.english.php file so I can see what page ppl are looking at on the main website.  Got that working good.

I noticed if ppl goto the website and not the forum they dont show up on the online today list.  But they are logged into the forum using ssi.  If they goto the forum then they show up on the online today list.

What code do i need to put on my website pages so that they show up on the online today list?
Title: Re: Users Online Today Mod
Post by: Pierre29200 on June 01, 2007, 10:07:14 AM
Add in mod&nbsp; version 1.4.0 joined :
french language and
dilbermc Theme
modifications included.

You can have dilbermc Theme only or French language only and the mod works with that you have.

You can use : http://modparser.dev.dansoftaustralia.net/
to see what i add for french language and dilbermc theme and to do these modifications manually if you prefer...

Hope it helps !

Pierre
Title: Re: Users Online Today Mod
Post by: askepott on June 07, 2007, 02:48:19 PM
Quote from: uni on April 30, 2007, 05:30:30 AM
Quote from: Dud on April 28, 2007, 01:57:44 PM
Help Me...all mine says is   : 2 (: 2, : 0)
Yigal, GPGrieco

No picture no nothing Please Help

Im using 1.12

Same thing. I'm using the default theme and a fresh install.

EDIT: Found it. Open your Modifications.english-utf8.php in the language folder inside your default them and add this:
$txt['uot_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';

hey thanks! it worked ;D HAHA
Title: Re: Users Online Today Mod
Post by: dazlia on June 08, 2007, 07:16:35 AM
guys need some help please.

Ive installed it (on 1.1.2) and everythihng appeared to be ok. However, I cant actually find the 'info centre' to find the information that this mod is supposed to give you.

Any ideas please?

Sorry......im a new to SMF :)

could someone pl4ease mail me at [email protected] as im at work at the moment.

cheers
Title: Re: Users Online Today Mod
Post by: HOCBOT on June 25, 2007, 07:08:48 AM
i have installed the mod and below i get the txt before the logo right at very top of page.

$txt['uot_users_online_today']='Users Logged In Today'; $txt['uot_yesterday']='Yesterday at '; $txt['uot_total']='Total'; $txt['uot_visible']='Visible'; $txt['uot_hidden']='Hidden';

www.houseofcommodores.com/forum1

running the dark red theme

if anyone can help would be great
Title: Re: Users Online Today Mod
Post by: InsaneMustang on June 25, 2007, 02:47:17 PM
This has to be the most confusingly written mod ever.  I've read all 34 pages of this thread, and I am extremely confused.

I realize that the mod.xml file displays the changes that need to be made in each file, but what the crap is this stuff?

<file name="$sourcedir/BoardIndex.php">

There isn't a file called that in my theme or in the default theme.  Does that mean boardindex.template.php ?

Same with this
<file name="$sourcedir/Stats.php">
does this mean stats.template.php and should all of these edits be done in the theme im using or the default.

Title: Re: Users Online Today Mod
Post by: symon on June 25, 2007, 04:55:07 PM
Quote from: InsaneMustang on June 25, 2007, 02:47:17 PM
This has to be the most confusingly written mod ever.  I've read all 34 pages of this thread, and I am extremely confused.

I realize that the mod.xml file displays the changes that need to be made in each file, but what the crap is this stuff?

<file name="$sourcedir/BoardIndex.php">

There isn't a file called that in my theme or in the default theme.  Does that mean boardindex.template.php ?

Same with this
<file name="$sourcedir/Stats.php">
does this mean stats.template.php and should all of these edits be done in the theme im using or the default.



They're in your sources directory :)
Title: Re: Users Online Today Mod
Post by: InsaneMustang on June 25, 2007, 08:25:05 PM
Dang, no wonder I couldn't find them.  That little bit of info should be made into the mod's stuff so you can find it.
Title: Re: Users Online Today Mod
Post by: Viceroy on June 26, 2007, 02:37:38 AM
Please let me know when this mod is available for 1.1.3 :)
Title: Re: Users Online Today Mod
Post by: Photoshocker on June 26, 2007, 05:25:01 AM
Quote from: symon on May 16, 2007, 08:50:17 AM
Has anyone also worked out how to log guests yet? Tucker? ;) hehe

It would make the stats look far more impressive. Afterall, this mod is supposed to be a way to convince visitors it's an active forum :)

Im also trying to find this out..anyone knows how?
Title: Re: Users Online Today Mod
Post by: qubbah on June 29, 2007, 09:21:56 AM
How can i made user ONLINE in two days or 48 hours?
Title: Re: Users Online Today Mod
Post by: kamili34 on July 01, 2007, 08:29:40 PM
Thanks for mod. :)
Title: Re: Users Online Today Mod
Post by: Pranav on July 01, 2007, 10:19:35 PM
Is this mod available for smf 1.1.3 ?
Title: Re: Users Online Today Mod
Post by: kamili34 on July 02, 2007, 12:44:46 AM
Yes and it works correct.   ;)
Title: Re: Users Online Today Mod
Post by: Pranav on July 02, 2007, 01:22:58 AM
Quote from: Photoshocker on June 26, 2007, 05:25:01 AM
Quote from: symon on May 16, 2007, 08:50:17 AM
Has anyone also worked out how to log guests yet? Tucker? ;) hehe

It would make the stats look far more impressive. Afterall, this mod is supposed to be a way to convince visitors it's an active forum :)

Im also trying to find this out..anyone knows how?

Me too i am trying to find the same thing..Actually some users think that we got less visitors daily but if we can log guests then it would be better because users get attracted more. :D
Title: Re: Users Online Today Mod
Post by: Chris369 on July 08, 2007, 06:35:12 AM
Hi guys

Why do I get this at the top of every page when I install this mod? I'm using 1.1.2 and default theme.

(http://img255.imageshack.us/img255/1619/untitledij9.th.jpg) (http://img255.imageshack.us/my.php?image=untitledij9.jpg)
Title: Re: Users Online Today Mod
Post by: Chris369 on July 08, 2007, 10:43:06 AM
Anyone? I'm sure this is a general problem because I get it with other mods too.
Title: Re: Users Online Today Mod
Post by: Chris369 on July 08, 2007, 12:10:27 PM
Ok ignore that, someone else helped me in another thread.

For anyone else with this problem read this post - http://www.simplemachines.org/community/index.php?topic=114701.msg1154351#msg1154351
Title: Re: Users Online Today Mod
Post by: souljaa on July 08, 2007, 08:49:58 PM
Quote from: Tick on April 21, 2007, 08:46:44 AM
Quote from: a.D on April 20, 2007, 08:12:14 PM
This installed fine on the forum, but it doesn't display on the Dilber theme I'm using.

Can someone help?


I posted this a few pages back.  This is how to make it work with dilber mc.     http://www.simplemachines.org/community/index.php?topic=55513.msg1001561#msg1001561

Would it be the same for other themes?
Thanks
Souljaa
Title: Re: Users Online Today Mod
Post by: Haruah on July 11, 2007, 08:37:47 AM
Thanx for the great MOD!  :)
Title: Re: Users Online Today Mod
Post by: Bigguy on July 11, 2007, 11:10:34 AM
Have you asked Carceri if you can release his mod like this Haruah ??? The mod author should be asked first before this is done. You could submit the language translations to him.
Title: Re: Users Online Today Mod
Post by: Haruah on July 11, 2007, 11:13:50 AM
Ok, I didn't know that. I'll remove it. Sorry.
I didn't mean to ... infringe on anything.
Title: Re: Users Online Today Mod
Post by: Bigguy on July 11, 2007, 11:15:02 AM
Oh your not and it was nice of you to go to all that work with the mod. The author should be asked first though. I would think sending him a PM to ask would be ok. ;)
Title: Re: Users Online Today Mod
Post by: Haruah on July 11, 2007, 11:19:45 AM
Yeah, I'll try that a bit later, don't have time right now.
I know the author should be asked first, but it's just that I'm so used to Joomla and it's GPL, so I have completely forgotten that SMF is not released under GPL license, therefore neither it's mods.
Sorry once again.
Title: Re: Users Online Today Mod
Post by: Bigguy on July 11, 2007, 11:21:18 AM
No problem at all I understand. :)
Title: Re: Users Online Today Mod
Post by: eminent on July 12, 2007, 08:36:03 PM
Hello,

I was looking at your mod, and I was wondering if it can keep history and view the users that logged in for "Today"/last 24 hours/ yesterday/   month-day-year logs..

So I am wondering if I can/this is:
a mod/block/script that will make a thread in the forum(for history).. at the end of the day, of the people who logged in..

for example in the forum:

A thread is made:

Monday, July 9th 2007(clicked)

post says>

USER 1 (time) of the last active
USER 2 (time) etc..

Then Locks the thread..

Then the next day.. etc..(so that there is a log of the people login in everyday, and also what time they were last active/last logged in)Something of this sort..


I know Im asking too much.. but i must be  ???

===
Is this even possible?!?!

It dont even have to be posted on the forum, it can also just keep history for admins/moderators to view, and admins/moderators can post it on thread..

Thanks in advance..
-Eminent
Title: Re: Users Online Today Mod
Post by: souljaa on July 15, 2007, 04:33:54 PM
Hey, the mod works great! Just installed it, but I'm having a little problem.
At the bottom, it says,
Quote: 5 (: 5, : 0)
5 meaning the number of users logged in, but I'm wondering what the rest is? And how would I change that, so that before the : , I could put "Users Online Today".
Thanks in advance!
- Souljaa
Title: Re: Users Online Today Mod
Post by: Stargater59 on July 17, 2007, 12:32:35 PM
You need to add the text strings into the modifications.english.php file.

Find that file in your forums directory
Themes/default/languages/Modifications.english.php

And paste this code at the bottom before the ending ?>

<![CDATA[$txt['uot_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';]]>


Is this mod going to be updated for 1.1.3?
Title: Re: Users Online Today Mod
Post by: Cool999 on July 20, 2007, 09:51:28 AM
Hello Everyone.

I want that in the members list it should show the users who r online in last 2 or 3 or 4 days................................

BUt the text "Users Logged In Today" Should Remain Same.

Hope u got it.

Thanks
Title: Re: Users Online Today Mod
Post by: Cool999 on July 27, 2007, 12:48:47 PM
Will Anyone Help Me.

Quote from: Cool999 on July 20, 2007, 09:51:28 AM
Hello Everyone.

I want that in the members list it should show the users who r online in last 2 or 3 or 4 days................................

BUt the text "Users Logged In Today" Should Remain Same.

Hope u got it.

Thanks
Title: Re: Users Online Today Mod
Post by: pirat3 on July 30, 2007, 11:20:03 PM
hi can anyone tell me what files i need to edit for aa new daamage?
Title: Re: Users Online Today Mod
Post by: t0AsD on August 01, 2007, 09:44:38 AM
Quote from: Stargater59 on July 17, 2007, 12:32:35 PM
Is this mod going to be updated for 1.1.3?

Works fine, just installed it on my 1.1.3.
Title: Re: Users Online Today Mod
Post by: Cool999 on August 01, 2007, 09:58:54 AM
When a will get a reply. Hope so this year

Quote from: Cool999 on July 27, 2007, 12:48:47 PM
Will Anyone Help Me.

Quote from: Cool999 on July 20, 2007, 09:51:28 AM
Hello Everyone.

I want that in the members list it should show the users who r online in last 2 or 3 or 4 days................................

BUt the text "Users Logged In Today" Should Remain Same.

Hope u got it.

Thanks
Title: Re: Users Online Today Mod
Post by: mikeandike on August 04, 2007, 11:27:47 PM
This mod is installed on my forum, and i edited the Board.Index.Template.php file accordingly, but it doesn't change at all. Here's the php code...


function template_main()
{
   global $context, $settings, $options, $txt, $scripturl, $modSettings;

   // Show some statistics next to the link tree if SP1 info is off.
   echo '
<table width="100%" cellpadding="3" cellspacing="0">
   <tr>
      <td valign="bottom">', theme_linktree(), '</td>
      <td align="right">';
   if (!$settings['show_sp1_info'])
      echo '
         ', $txt[19], ': ', $context['common_stats']['total_members'], ' &nbsp;&#8226;&nbsp; ', $txt[95], ': ', $context['common_stats']['total_posts'], ' &nbsp;&#8226;&nbsp; ', $txt[64], ': ', $context['common_stats']['total_topics'], '
         ', ($settings['show_latest_member'] ? '<br />' . $txt[201] . ' <b>' . $context['common_stats']['latest_member']['link'] . '</b>' . $txt[581] : '');
   echo '
      </td>
   </tr>
</table>';

   // Show the news fader?  (assuming there are things to show...)
   if ($settings['show_newsfader'] && !empty($context['fader_news_lines']))
   {
      echo '
<div class="tborder" style="margin-bottom: 2ex;">
   <table border="0" width="100%" cellspacing="1" cellpadding="4">
      <tr class="titlebg" align="center">
         <td>', $txt[102], '</td>
      </tr>
      <tr>
         <td valign="middle" align="center" style="height: 60px;">';

      // Prepare all the javascript settings.
      echo '
            <div id="smfFadeScroller" style="width: 90%; padding: 2px;"><b>', $context['news_lines'][0], '</b></div>
            <script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
               // The fading delay (in ms.)
               var smfFadeDelay = ', empty($settings['newsfader_time']) ? 5000 : $settings['newsfader_time'], ';
               // Fade from... what text color?  To which background color?
               var smfFadeFrom = {"r": 0, "g": 0, "b": 0}, smfFadeTo = {"r": 255, "g": 255, "b": 255};
               // Surround each item with... anything special?
               var smfFadeBefore = "<b>", smfFadeAfter = "</b>";

               var foreColor, backEl, backColor;

               if (typeof(document.getElementById(\'smfFadeScroller\').currentStyle) != "undefined")
               {
                  foreColor = document.getElementById(\'smfFadeScroller\').currentStyle.color.match(/#([\da-f][\da-f])([\da-f][\da-f])([\da-f][\da-f])/);
                  smfFadeFrom = {"r": parseInt(foreColor[1]), "g": parseInt(foreColor[2]), "b": parseInt(foreColor[3])};

                  backEl = document.getElementById(\'smfFadeScroller\');
                  while (backEl.currentStyle.backgroundColor == "transparent" && typeof(backEl.parentNode) != "undefined")
                     backEl = backEl.parentNode;

                  backColor = backEl.currentStyle.backgroundColor.match(/#([\da-f][\da-f])([\da-f][\da-f])([\da-f][\da-f])/);
                  smfFadeTo = {"r": eval("0x" + backColor[1]), "g": eval("0x" + backColor[2]), "b": eval("0x" + backColor[3])};
               }
               else if (typeof(window.opera) == "undefined" && typeof(document.defaultView) != "undefined")
               {
                  foreColor = document.defaultView.getComputedStyle(document.getElementById(\'smfFadeScroller\'), null).color.match(/rgb\((\d+), (\d+), (\d+)\)/);
                  smfFadeFrom = {"r": parseInt(foreColor[1]), "g": parseInt(foreColor[2]), "b": parseInt(foreColor[3])};

                  backEl = document.getElementById(\'smfFadeScroller\');
                  while (document.defaultView.getComputedStyle(backEl, null).backgroundColor == "transparent" && typeof(backEl.parentNode) != "undefined" && typeof(backEl.parentNode.tagName) != "undefined")
                     backEl = backEl.parentNode;

                  backColor = document.defaultView.getComputedStyle(backEl, null).backgroundColor.match(/rgb\((\d+), (\d+), (\d+)\)/);
                  smfFadeTo = {"r": parseInt(backColor[1]), "g": parseInt(backColor[2]), "b": parseInt(backColor[3])};
               }

               // List all the lines of the news for display.
               var smfFadeContent = new Array(
                  "', implode('",
                  "', $context['fader_news_lines']), '"
               );
            // ]]></script>
            <script language="JavaScript" type="text/javascript" src="', $settings['default_theme_url'], '/fader.js"></script>
         </td>
      </tr>
   </table>
</div>';
   }

   /* Each category in categories is made up of:
      id, href, link, name, is_collapsed (is it collapsed?), can_collapse (is it okay if it is?),
      new (is it new?), collapse_href (href to collapse/expand), collapse_image (up/down iamge),
      and boards. (see below.) */
   foreach ($context['categories'] as $category)
   {
      echo '
<div class="tborder"><table border="0" width="100%" cellspacing="1" cellpadding="5">
   <tr>
      <td colspan="4" class="catbg', $category['new'] ? '2' : '', '" height="18">';
      echo '
         ', $category['link'], '
      </td>
   </tr>';

      // Assuming the category hasn't been collapsed...
      if (!$category['is_collapsed'])
      {
         /* Each board in each category's boards has:
            new (is it new?), id, name, description, moderators (see below), link_moderators (just a list.),
            children (see below.), link_children (easier to use.), children_new (are they new?),
            topics (# of), posts (# of), link, href, and last_post. (see below.) */
         foreach ($category['boards'] as $board)
         {
            echo '
   <tr class="windowbg2">
      <td class="windowbg" width="6%" align="center" valign="top"><a href="', $scripturl, '?action=unread;board=', $board['id'], '.0">';

            // If the board is new, show a strong indicator.
            if ($board['new'])
               echo '<img src="', $settings['images_url'], '/on.gif" alt="', $txt[333], '" title="', $txt[333], '" border="0" />';
            // This board doesn't have new posts, but its children do.
            elseif ($board['children_new'])
               echo '<img src="', $settings['images_url'], '/on.gif" alt="', $txt[333], '" title="', $txt[333], '" border="0" />';
            // No new posts at all!  The agony!!
            else
               echo '<img src="', $settings['images_url'], '/off.gif" alt="', $txt[334], '" title="', $txt[334], '" border="0" />';

            echo '</a></td>
      <td class="windowbg">
         <b><a href="', $board['href'], '" name="b', $board['id'], '">', $board['name'], '</a></b><br />
         ', $board['description'];

            // Show the "Moderators: ".  Each has name, href, link, and id. (but we're gonna use link_moderators.)
            if (!empty($board['moderators']))
               echo '
         <div style="padding-top: 1px;" class="smalltext2"><i>', count($board['moderators']) == 1 ? $txt[298] : $txt[299], ': ', implode(', ', $board['link_moderators']), '</i></div>';

            // Show the "Child Boards: ". (there's a link_children but we're going to bold the new ones...)
            if (!empty($board['children']))
            {
               // Sort the links into an array with new boards bold so it can be imploded.
               $children = array();
               /* Each child in each board's children has:
                  id, name, description, new (is it new?), topics (#), posts (#), href, link, and last_post. */
               foreach ($board['children'] as $child)
               {
                  $child['link'] = '<a href="' . $child['href'] . '" title="' . ($child['new'] ? $txt[333] : $txt[334]) . ' (' . $txt[330] . ': ' . $child['topics'] . ', ' . $txt[21] . ': ' . $child['posts'] . ')">' . $child['name'] . '</a>';
                  $children[] = $child['new'] ? '<b>' . $child['link'] . '</b>' : $child['link'];
               }

               echo '
         <div style="padding-top: 1px;" class="smalltext2"><i>', $txt['parent_boards'], ': ', implode(', ', $children), '</i></div>';
            }

            // Show some basic information about the number of posts, etc.
            echo '
      </td>
      <td class="windowbg" valign="middle" align="center" style="width: 12ex;"><span class="smalltext2">
         ', $board['posts'], ' ', $txt[21], ' ', $txt['smf88'], '<br />
         ', $board['topics'], ' ', $txt[330], '
      </span></td>
      <td class="smalltext" valign="middle" width="22%">';

            /* The board's and children's 'last_post's have:
               time, timestamp (a number that represents the time.), id (of the post), topic (topic id.),
               link, href, subject, start (where they should go for the first unread post.),
               and member. (which has id, name, link, href, username in it.) */
            if (!empty($board['last_post']['id']))
               echo '
         ', $txt[22], ' ', $txt[30], ' ', $board['last_post']['time'], '<br />
         ', $txt['smf88'], ' ', $board['last_post']['link'], ' ', $txt[525], ' ', $board['last_post']['member']['link'];

            echo '
      </td>
   </tr>';
         }
      }

      echo '
</table></div>
<br />';
   }

   if ($context['user']['is_logged'])
   {
      echo '
<div class="tborder" style="padding: 3px;"><table border="0" width="100%" cellspacing="0" cellpadding="5">
   <tr class="titlebg">
      <td align="', !$context['right_to_left'] ? 'left' : 'right', '" class="smalltext">
         <img src="' . $settings['images_url'] . '/on.gif" alt="" border="0" align="middle" /> ', $txt[333], '
         <img src="' . $settings['images_url'] . '/off.gif" alt="" border="0" align="middle" style="margin-left: 4ex;" /> ', $txt[334], '
      </td>
      <td align="', !$context['right_to_left'] ? 'right' : 'left', '" class="smalltext">';
      // Show the mark all as read button?
      if ($settings['show_mark_read'])
         echo '
         <a href="', $scripturl, '?action=markasread;sa=all;sesc=' . $context['session_id'] . '">', ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/markread.gif" alt="' . $txt[452] . '" border="0" />' : $txt[452]), '</a>';
      echo '
      </td>
   </tr>
</table></div>';
   }

   // Here's where the "Info Center" starts...
   echo '
<br />
<div class="tborder"><table border="0" width="100%" cellspacing="1" cellpadding="4">
   <tr class="titlebg">
      <td align="center" colspan="2">', $txt[685], '</td>
   </tr>';

   // This is the "Recent Posts" bar.
   if (!empty($settings['number_recent_posts']))
   {
      echo '
   <tr>
      <td class="catbg" colspan="2">', $txt[214], '</td>
   </tr>
   <tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         <a href="', $scripturl, '?action=recent">
            <img src="', $settings['images_url'], '/post/xx.gif" alt="', $txt[214], '" border="0" /></a>
      </td>
      <td class="windowbg2">';

      // Only show one post.
      if ($settings['number_recent_posts'] == 1)
      {
         // latest_post has link, href, time, subject, short_subject (shortened with...), and topic. (its id.)
         echo '
         <b><a href="', $scripturl, '?action=recent">', $txt[214], '</a></b>
         <div class="smalltext">
            ', $txt[234], ' &quot;', $context['latest_post']['link'], '&quot; ', $txt[235], ' (', $context['latest_post']['time'], ')<br />
         </div>';
      }
      // Show lots of posts.
      elseif (!empty($context['latest_posts']))
      {
         echo '
         <table width="100%" border="0">';
         /* Each post in latest_posts has:
            board (with an id, name, and link.), topic (the topic's id.), poster (with id, name, and link.),
            subject, short_subject (shortened with...), time, link, and href. */
         foreach ($context['latest_posts'] as $post)
            echo '
            <tr>
               <td align="right" valign="top" nowrap="nowrap">[', $post['board']['link'], ']</td>
               <td valign="top">', $post['link'], ' ', $txt[525], ' ', $post['poster']['link'], '</td>
               <td align="right" valign="top" nowrap="nowrap">', $post['time'], '</td>
            </tr>';
         echo '
         </table>';
      }
      echo '
      </td>
   </tr>';
   }

   // Show information about events, birthdays, and holidays on the calendar.
   if ($context['show_calendar'])
   {
      echo '
   <tr>
      <td class="catbg" colspan="2">', $context['calendar_only_today'] ? $txt['calendar47b'] : $txt['calendar47'], '</td>
   </tr><tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         <a href="', $scripturl, '?action=calendar">
            <img src="', $settings['images_url'], '/icons/calendar.gif" alt="', $txt['calendar24'], '" border="0" /></a>
      </td>
      <td class="windowbg2" width="100%">
         <span class="smalltext2">';

      // Holidays like "Christmas", "Chanukah", and "We Love [Unknown] Day" :P.
      if (!empty($context['calendar_holidays']))
         echo '
            <span style="color: #', $modSettings['cal_holidaycolor'], ';">', $txt['calendar5'], ' ', implode(', ', $context['calendar_holidays']), '</span><br />';

      // People's birthdays.  Like mine.  And yours, I guess.  Kidding.
      if (!empty($context['calendar_birthdays']))
      {
         echo '
            <span style="color: #', $modSettings['cal_bdaycolor'], ';">', $context['calendar_only_today'] ? $txt['calendar3'] : $txt['calendar3b'], '</span> ';
         /* Each member in calendar_birthdays has:
            id, name (person), age (if they have one set?), is_last. (last in list?), and is_today (birthday is today?) */
         foreach ($context['calendar_birthdays'] as $member)
            echo '
            <a href="', $scripturl, '?action=profile;u=', $member['id'], '">', $member['is_today'] ? '<b>' : '', $member['name'], $member['is_today'] ? '</b>' : '', isset($member['age']) ? ' (' . $member['age'] . ')' : '', '</a>', $member['is_last'] ? '<br />' : ', ';
      }
      // Events like community get-togethers.
      if (!empty($context['calendar_events']))
      {
         echo '
            <span style="color: #', $modSettings['cal_eventcolor'], ';">', $context['calendar_only_today'] ? $txt['calendar4'] : $txt['calendar4b'], '</span> ';
         /* Each event in calendar_events should have:
            title, href, is_last, can_edit (are they allowed?), modify_href, and is_today. */
         foreach ($context['calendar_events'] as $event)
            echo '
            ', $event['can_edit'] ? '<a href="' . $event['modify_href'] . '" style="color: #FF0000;">*</a> ' : '', $event['href'] == '' ? '' : '<a href="' . $event['href'] . '">', $event['is_today'] ? '<b>' . $event['title'] . '</b>' : $event['title'], $event['href'] == '' ? '' : '</a>', $event['is_last'] ? '<br />' : ', ';

         // Show a little help text to help them along ;).
         if ($context['calendar_can_edit'])
            echo '
            (<a href="', $scripturl, '?action=helpadmin;help=calendar_how_edit" onclick="return reqWin(this.href);">', $txt['calendar_how_edit'], '</a>)';
      }
      echo '
         </span>
      </td>
   </tr>';
// Users online today

   echo '
   <tr>
      <td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
   </tr><tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         <img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
      </td>
      <td class="windowbg2" width="100%">';

   echo '
         <div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
     echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

   // Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
   if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
      echo '<br />', implode(', ', $context['list_users_online_today']);

   echo '
            <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
            <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
         </div>
      </td>
   </tr>';
   }

   // Show a member bar.  Not heavily ornate, but functional at least.
   if ($settings['show_member_bar'])
   {
      echo '
   <tr>
      <td class="catbg" colspan="2">', $txt[331], '</td>
   </tr>
   <tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         ', $context['show_member_list'] ? '<a href="' . $scripturl . '?action=mlist">' : '', '<img src="', $settings['images_url'], '/icons/members.gif" alt="', $txt[332], '" border="0" />', $context['show_member_list'] ? '</a>' : '', '
      </td>
      <td class="windowbg2" width="100%">
         <b>', $context['show_member_list'] ? '<a href="' . $scripturl . '?action=mlist">' . $txt[332] . '</a>' : $txt[332], '</b>
         <div class="smalltext2">', $txt[200], '</div>
      </td>
   </tr>';
   }

   // Show YaBB SP1 style information...
   if ($settings['show_sp1_info'])
   {
      echo '
   <tr>
      <td class="catbg" colspan="2">', $txt[645], '</td>
   </tr>
   <tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         <a href="', $scripturl, '?action=stats">
            <img src="', $settings['images_url'], '/icons/info.gif" alt="', $txt[645], '" border="0" /></a>
      </td>
      <td class="windowbg2" width="100%">
         <table border="0" width="90%"><tr>
            <td class="smalltext2">
               <div style="float: ', !$context['right_to_left'] ? 'left' : 'right', '; width: 50%;">', $txt[490], ': <b>', $context['common_stats']['total_topics'], '</b></div>', $txt[489], ': <b>', $context['common_stats']['total_posts'], '</b><br />', !empty($context['latest_post']) ? '
               ' . $txt[659] . ': &quot;' . $context['latest_post']['link'] . '&quot;  (' . $context['latest_post']['time'] . ')<br />' : '', '
               <a href="', $scripturl, '?action=recent">', $txt[234], '</a>', $context['show_stats'] ? '<br />
               <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
            </td>
            <td width="32%" class="smalltext2" valign="top">
               ', $txt[488], ': <b><a href="', $scripturl, '?action=mlist">', $context['common_stats']['total_members'], '</a></b><br />
               ', $txt[656], ': <b>', $context['common_stats']['latest_member']['link'], '</b><br />';
      // If they are logged in, show their unread message count, etc..
      if ($context['user']['is_logged'])
         echo '
               ', $txt['smf199'], ': <b><a href="', $scripturl, '?action=pm">', $context['user']['messages'], '</a></b> ', $txt['newmessages3'], ': <b><a href="', $scripturl, '?action=pm">', $context['user']['unread_messages'], '</a></b>';
      echo '
            </td>
         </tr></table>
      </td>
   </tr>';
   }

   // "Users online" - in order of activity.
   echo '

<tr>
      <td class="catbg" colspan="2">', $txt[158], '</td>
   </tr><tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         ', $context['show_who'] ? '<a href="' . $scripturl . '?action=who">' : '', '<img src="',
$settings['images_url'], '/icons/online.gif" alt="', $txt[158], '" border="0" />', $context['show_who'] ?
'</a>' : '', '     
</td>

      <td class="windowbg2" width="100%">';

   if ($context['show_who'])
      echo '
         <a href="', $scripturl, '?action=who">';

   echo $context['num_guests'], ' ', $context['num_guests'] == 1 ? $txt['guest'] : $txt['guests'], ', ' . $context['num_users_online'], ' ', $context['num_users_online'] == 1 ? $txt['user'] : $txt['users'];

   // Handle hidden users and buddies.
   if (!empty($context['num_users_hidden']) || ($context['show_buddies'] && !empty($context['show_buddies'])))
   {
      echo ' (';

      // Show the number of buddies online?
      if ($context['show_buddies'])
         echo $context['num_buddies'], ' ', $context['num_buddies'] == 1 ? $txt['buddy'] : $txt['buddies'];

      // How about hidden users?
      if (!empty($context['num_users_hidden']))
         echo $context['show_buddies'] ? ', ' : '', $context['num_users_hidden'] . ' ' . $txt['hidden'];

      echo ')';
   }

   if ($context['show_who'])
      echo '</a>';

   echo '
         <div class="smalltext2">';

   // Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
   if (!empty($context['users_online']))
      echo '
            ', $txt[140], ':<br />', implode(', ', $context['list_users_online']);

   echo '
            <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
            <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
       
</div>
<hr />
Membergroup Legend- <font color="aquamarine">[Headmaster]</font> <font color="#FF9966">[Deputy Headmaster]</font> <font color="#FF0000">[Gryffindor]</font> <font color="#FFFF00">[Hufflepuff]</font> <font color="#0066FF">[Ravenclaw]</font> <font color="#00FF00">[Slytherin]</font> <font color="#3fb45e">[Death Eater]</font> <font color="#CC00CC">[Dark Wizard]</font> <font color=gray>[Creature]</font>
<br>

<font color="#CCCCFF">[Adult Wizard]</font> <font color="#339966">[Mediwizard]</font> <font color="#99FF33">[Ministry of Magic]</font> <font color="#FF9900">[Order of the Phoenix]</font> <font color="#0000FF">[Pro Quidditch Player]</font> <font color="#FF3399">[Professor]</font> <font color="#993333">[Shop Keeper]</font> <font color="#669900">[The Dark Lord]</font> <font color="#CC99CC">[Daily Prophet]</font>
<br>
<br>
      </td>
   </tr>';


   // If they are logged in, but SP1 style information is off... show a personal message bar.
   if ($context['user']['is_logged'] && !$settings['show_sp1_info'])
   {
      echo '
   <tr>
      <td class="catbg" colspan="2">', $txt[159], '</td>
   </tr><tr>
      <td class="windowbg" width="20" valign="middle" align="center">
         ', $context['allow_pm'] ? '<a href="' . $scripturl . '?action=pm">' : '', '<img src="', $settings['images_url'], '/message_sm.gif" alt="', $txt[159], '" border="0" />', $context['allow_pm'] ? '</a>' : '', '
      </td>
      <td class="windowbg2" valign="top">
         <b><a href="', $scripturl, '?action=pm">', $txt[159], '</a></b>
         <div class="smalltext">
            ', $txt[660], ' ', $context['user']['messages'], ' ', $context['user']['messages'] == 1 ? $txt[471] : $txt[153], '.... ', $txt[661], ' <a href="', $scripturl, '?action=pm">', $txt[662], '</a> ', $txt[663], '
         </div>
      </td>
   </tr>';
   }

   // Show the login bar. (it's only true if they are logged out anyway.)
   if ($context['show_login_bar'])
   {
      echo '
   <tr>
      <td class="catbg" colspan="2">', $txt[34], ' <a href="', $scripturl, '?action=reminder" class="smalltext">(' . $txt[315] . ')</a></td>
   </tr>
   <tr>
      <td class="windowbg" width="20" align="center">
         <a href="', $scripturl, '?action=login">
            <img src="', $settings['images_url'], '/icons/login.gif" alt="', $txt[34], '" border="0" /></a>
      </td>
      <td class="windowbg2" valign="middle">
         <form action="', $scripturl, '?action=login2" method="post" style="margin: 0;">
            <table border="0" cellpadding="2" cellspacing="0" width="100%"><tr>
               <td valign="middle" align="left">
                  <label for="user"><b>', $txt[35], ':</b><br /><input type="text" name="user" id="user" size="15" /></label>
               </td>
               <td valign="middle" align="left">
                  <label for="passwrd"><b>', $txt[36], ':</b><br /><input type="password" name="passwrd" id="passwrd" size="15" /></label>
               </td>
               <td valign="middle" align="left">
                  <label for="cookielength"><b>', $txt[497], ':</b><br /><input type="text" name="cookielength" id="cookielength" size="4" maxlength="4" value="', $modSettings['cookieTime'], '" /></label>
               </td>
               <td valign="middle" align="left">
                  <label for="cookieneverexp"><b>', $txt[508], ':</b><br /><input type="checkbox" name="cookieneverexp" id="cookieneverexp" checked="checked" class="check" /></label>
               </td>
               <td valign="middle" align="left">
                  <input type="submit" value="', $txt[34], '" />
               </td>
            </tr></table>
         </form>
      </td>
   </tr>';
   }

   echo '
</table></div>';
}


I'm not getting any parse or template errors, just no change. The mod is installed and applied. Ideas?
Title: Re: Users Online Today Mod
Post by: Paracelsus on August 05, 2007, 03:29:21 PM
Quote from: Webrunner on December 27, 2006, 05:31:55 PM
Quote from: mcalan2001 on December 13, 2006, 02:39:52 PM
Quote from: akabugeyes on September 24, 2006, 10:57:01 AM
It is not random. It is by the time they last logged in.
This is untested, but you can try changing in Sources/BoardIndex.php

$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(

to

$context['users_online_today'][$row['memberName']] = array(

I think that needs to be much the same edit, but about ten lines down. However I'm no expert and it put the members in reverse alphabetic order. I couldn't see why. So I'll leave it to somebody who knows what they are doing. Please.  :D

Find:

krsort($context['users_online_today']);
krsort($context['list_users_online_today']);


change into:

ksort($context['users_online_today']);
ksort($context['list_users_online_today']);


and the reverse sorting is over ;)


Sorry to get back on this...

I installed the MOD which works perfectly (congrats to the author!) and then used this little modification to put the users in alphabetical order. The problem is that they are ordered based on ASCII principles, in which the uppercase alphabet comes first and only then the lowercase (and the numbers come somewhat randomly I guess).

How can I fix this in order that it doesn't matter if its upper or lower case? (I've read something before about ORDER BY UPPER but have no idea how to do it)
Title: Re: Users Online Today Mod
Post by: pirat3 on August 13, 2007, 01:03:01 AM
Can anyone please tell me how to allow GUESTS to see this?
Title: Re: Users Online Today Mod
Post by: SA™ on August 13, 2007, 02:10:19 AM
admin permisions guest look for Googlebot & Spiders   
View Googlebot & Spiders and tick the box hope this helps
Title: Re: Users Online Today Mod
Post by: vipmoney on August 19, 2007, 05:13:04 PM

Heres a SSI function for this mod
(I'm no expert, please test it at your own risk)


function ssi_usersonlinetoday($output_method = 'echo')
{
global $txt, $scripturl, $db_prefix, $ID_MEMBER, $user_info, $sourcedir;
global $modSettings, $context, $settings, $options;
// Users online today
// Load the users online today.
$date = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $date['mon'], $date['mday'], $date['year']) - ($modSettings['time_offset'] * 3600);

$s = strpos($user_info['time_format'], '%S') === false ? '' : ':%S';
if (strpos($user_info['time_format'], '%H') === false && strpos($user_info['time_format'], '%T') === false)
$time_fmt = '%I:%M' . $s . ' %p';
else
$time_fmt = '%H:%M' . $s;

$result = db_query("
SELECT
mem.ID_MEMBER, mem.lastLogin, mem.realName, mem.memberName, mem.showOnline,
mg.onlineColor, mg.ID_GROUP, mg.groupName
FROM {$db_prefix}members AS mem
LEFT JOIN {$db_prefix}membergroups AS mg ON (mg.ID_GROUP = IF(mem.ID_GROUP = 0, mem.ID_POST_GROUP, mem.ID_GROUP)) WHERE mem.lastLogin >= $midnight", __FILE__, __LINE__);

$context['num_hidden_users_online_today'] = 0;
$context['users_online_today'] = array();
$context['list_users_online_today'] = array();
//$context['num_users_online_today'] = array();


while ($row = mysql_fetch_assoc($result))
{
if (empty($row['showOnline']))
{
$context['num_hidden_users_online_today'] = $context['num_hidden_users_online_today'] + 1;
if (!$user_info['is_admin']) continue;
}

$userday = strftime('%d', forum_time(true));
$loginday = strftime('%d', forum_time(true, $row['lastLogin']));
$yesterday = $userday == $loginday ? '' : $txt['uot_yesterday'];

$lastLogin = $yesterday . strftime($time_fmt, forum_time(true, $row['lastLogin']));
$title = ' title="' . $lastLogin . '"';

// Some basic color coding...
if (!empty($row['onlineColor']))
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['ID_MEMBER'] . '"' . $title . ' style="color: ' . $row['onlineColor'] . ';">' . $row['realName'] . '</a>';
else
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['ID_MEMBER'] . '"' . $title . '>' . $row['realName'] . '</a>';

$is_buddy = in_array($row['ID_MEMBER'], $user_info['buddies']);
if ($is_buddy)
{
$link = '<b>' . $link . '</b>';
}

$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
'id' => $row['ID_MEMBER'],
'username' => $row['memberName'],
'name' => $row['realName'],
'group' => $row['ID_GROUP'],
'href' => $scripturl . '?action=profile;u=' . $row['ID_MEMBER'],
'link' => $link,
'is_buddy' => $is_buddy,
'hidden' => empty($row['showOnline']),
);

$context['list_users_online_today'][$row['lastLogin'] . $row['memberName']] = empty($row['showOnline']) ? '<i>' . $link . '</i>' : $link;
}
mysql_free_result($result);

krsort($context['users_online_today']);
krsort($context['list_users_online_today']);

$context['num_users_online_today'] = count($context['users_online_today']);
if (!$user_info['is_admin'])
{
$context['num_users_online_today'] = $context['num_users_online_today'] + $context['num_hidden_users_online_today'];
}

//////////////// Showing the users:

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  //if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']))
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>';
}


Usage:
Put this code on the SSI.php and test it by calling it:
function ssi_usersonlinetoday()
Title: Re: Users Online Today Mod
Post by: Malek on August 21, 2007, 12:40:00 PM
Question - did anyone manage to install this on BlackDay theme? I tried but it seems that BoardIndex.template.php is missing the part that the modifications should be added before, and I dared not to proceed further.
Title: Re: Users Online Today Mod
Post by: TrueSatan on August 21, 2007, 02:07:15 PM
Where a file is not included in a theme the file of the same name from the SMF Default theme is automatically used...

If you set up a spare test forum and make your edits on that first and rename the original files  to, for instance, .phpold as you go and keep them in place in case you need to revert to them you need have no fear of making such changes. Once you get it working you can transfer the edited files to your main/live/production forum.
Title: Re: Users Online Today Mod
Post by: Malek on August 21, 2007, 02:14:33 PM
The problem is that the file exists but doesn't have needed part - the mod works correctly under default SMF theme, but not under BlackDay, so it seems it doesn't use default theme's file in any way.
Title: Re: Users Online Today Mod
Post by: TrueSatan on August 21, 2007, 03:06:07 PM
You can attempt to recode the BlackDay theme file to include the missing part and test it on a test forum or post on the topic in the themes forum here that reletes to that theme and see if the author of it or other users can help or switch to another theme or not use this mod...as I see it these are the choices before you.
Title: Re: Users Online Today Mod
Post by: L.G.S on August 21, 2007, 03:29:09 PM
Quote from: Malek on August 21, 2007, 12:40:00 PM
Question - did anyone manage to install this on BlackDay theme? I tried but it seems that BoardIndex.template.php is missing the part that the modifications should be added before, and I dared not to proceed further.

To add the mod is very easy to custom themes.
Title: Re: Users Online Today Mod
Post by: noaneo on August 26, 2007, 03:01:34 PM
Quote from: Stargater59 on July 17, 2007, 12:32:35 PM
You need to add the text strings into the modifications.english.php file.

Find that file in your forums directory
Themes/default/languages/Modifications.english.php

And paste this code at the bottom before the ending ?>

<![CDATA[$txt['uot_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';]]>


Is this mod going to be updated for 1.1.3?

Bonsoir,

Je viens d'installer ce mod mais je n'utilise pas le thème par défaut alors que faut-il modifier pour que le mod fonctionne dans mon thème?
Merci
Title: Re: Users Online Today Mod
Post by: Powerbob on August 29, 2007, 02:37:59 AM
Tell me, is this mod Dead? ie no more updates? The author hasn't posted since February 17, 2007, 02:46:38 AM, and has not been online since 31 July!
Title: Re: Users Online Today Mod
Post by: noaneo on August 29, 2007, 07:31:26 AM
Bonjour,

Il n'y a pas un mod equivalent ??
here is not an equivalent MOD??
Title: Re: Users Online Today Mod
Post by: Paracelsus on August 29, 2007, 08:10:57 AM
Quote from: Powerbob on August 29, 2007, 02:37:59 AM
Tell me, is this mod Dead? ie no more updates? The author hasn't posted since February 17, 2007, 02:46:38 AM, and has not been online since 31 July!

It doesn't need any more updates... it works perfectly as it is (well, I would personally put an update to get the list in alphabetical order... but that's me :P)
Title: Re: Users Online Today Mod
Post by: noaneo on August 29, 2007, 08:51:24 AM
But how to install it when one does not use the template by defect ??
Thank you
Title: Re: Users Online Today Mod
Post by: Paracelsus on August 29, 2007, 11:13:21 AM
You just look at the changes by opening the xml file (you can use the modifications parser to do it or just simply explore the file using the forum system after you installed the mod)... it states there all the changes made in every file...

... you just have to reproduce those changes which are made on files under the default theme directory tree in your own custom theme files. So if, for example, there's a change in BoardIndex.template.php - which exists in both default AND custom theme directory, then you MUST change the file in your custom directory with the exact changes that were made in the default directory file. If the file exists just in the default theme directory and NOT in the custom theme directory, then you have to do absolutely nothing, since the custom theme will "push/use" the file in the default directory... got it? ;)

BTW, I fixed the ordering problem  ;D ;D
uksort($myArray, "strnatcasecmp"); instead of ksort instruction.
Title: Re: Users Online Today Mod
Post by: noaneo on August 29, 2007, 11:57:32 AM
Thank you.

For this MOD what to reproduce in the other topics?

Thank you
Title: Re: Users Online Today Mod
Post by: Paracelsus on August 29, 2007, 12:18:36 PM
Damn it... can't you just read it?

In my case, I had to edit BoardIndex.Template.php and the language files (since mine are xxxxxx.portuguese-utf8.php). Since I don't have any Stats.Template.php in my own custom theme, I didn't had to edit that one.

If you read the file, even though it's in code, it's very understandable... so just read it and you'll figure it out for sure.
Title: Re: Users Online Today Mod
Post by: dxyy on August 30, 2007, 03:48:53 PM
Does this mod work for SMF1.1.3?
Title: Re: Users Online Today Mod
Post by: kamili34 on August 30, 2007, 08:16:15 PM
Quote from: hugodiaz on August 30, 2007, 03:48:53 PM
Does this mod work for SMF1.1.3?

Yes it works  :P
Title: Re: Users Online Today Mod
Post by: dxyy on September 01, 2007, 02:33:41 AM
Ok, I have some questions:

I want this to also be visible to guests, how can I do that?

Also, how can I make the entire list of users online today be displayed in alphabetical order?

After reading through a few pages of this thread I saw something about changing the order, but I didn't quite understand it. Any help would be greatly appreciated.

Thanks! :)
Title: Re: Users Online Today Mod
Post by: Paracelsus on September 01, 2007, 05:11:20 AM
Quote from: hugodiaz on September 01, 2007, 02:33:41 AM
Ok, I have some questions:

I want this to also be visible to guests, how can I do that?

Also, how can I make the entire list of users online today be displayed in alphabetical order?

After reading through a few pages of this thread I saw something about changing the order, but I didn't quite understand it. Any help would be greatly appreciated.

Thanks! :)


1. Visible to guests - have no idea :-[

2.
Quote from: Paracelsus on August 05, 2007, 03:29:21 PM
(...) changing in Sources/BoardIndex.php

$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(

to

$context['users_online_today'][$row['memberName']] = array(

(...) that needs to be much the same edit, but about ten lines down.

Find:

krsort($context['users_online_today']);
krsort($context['list_users_online_today']);


change boyh the lines using this instruction instead:
uksort($myArray, "strnatcasecmp");


And that's it!
Title: Re: Users Online Today Mod
Post by: ApplianceJunk on September 09, 2007, 06:04:55 PM
Hi,

I have this mod installed and it works great, thanks!
Does anyone know how I can us it in a TP block?

Thanks,
Title: Re: Users Online Today Mod
Post by: JiGs013 on September 16, 2007, 01:19:31 AM


i already installed the " Users_Online_Today_1.4.0.zip " and it works fine with the default theme but on my TP - Custom Themes it doesnt work.. can anyone tell me what will i do to make it work on my TP-Themes? i need manual install

thanks for advance
Title: Re: Users Online Today Mod
Post by: kamili34 on September 16, 2007, 05:17:10 AM
Yes you must manually some changes.
Title: Re: Users Online Today Mod
Post by: webou on September 19, 2007, 11:00:52 AM
Quote from: Pierre29200 on June 01, 2007, 10:07:14 AM
Add in mod&nbsp; version 1.4.0 joined :
french language and
dilbermc Theme
modifications included.

You can have dilbermc Theme only or French language only and the mod works with that you have.

You can use : http://modparser.dev.dansoftaustralia.net/
to see what i add for french language and dilbermc theme and to do these modifications manually if you prefer...

Hope it helps !

Pierre
Thank you, it helped very much :)
Title: Re: Users Online Today Mod
Post by: ~Kikoish~ on October 04, 2007, 04:50:49 AM
When will the update for 1.1.4 be release?
Title: Re: Users Online Today Mod
Post by: dxyy on October 04, 2007, 02:18:40 PM
Does anyone know how I can make this visible to guests?

I would really appreciate some help in that regard.

Thanks in advance. :)
Title: Re: Users Online Today Mod
Post by: Rica on October 06, 2007, 12:00:04 AM
Is it working on 1.1.4 ?
Title: Re: Users Online Today Mod
Post by: ramapoughnative1 on October 06, 2007, 02:38:12 AM
yes it does work on 1.1.4
Title: Re: Users Online Today Mod
Post by: christicehurst on October 09, 2007, 07:34:25 AM
This mod will be a problem with SMF 2.0. Anyone going to take over this mod soon?
Title: Re: Users Online Today Mod
Post by: symon on October 09, 2007, 06:42:10 PM
Another case of the user not being listened to.

I'm not surprised Vbulletin is so popular. Fantastic functionality.

This mod got done and the maker disappeared.

Typical smf support.  :o
Title: Re: Users Online Today Mod
Post by: Paracelsus on October 10, 2007, 03:00:00 AM
Quote from: symon on October 09, 2007, 06:42:10 PM
Another case of the user not being listened to.

I'm not surprised Vbulletin is so popular. Fantastic functionality.

This mod got done and the maker disappeared.

Typical smf support.  :o

What do you mean? Have you already asked if this feature will be available or not in SMF 2.0? Because if it is, there's no point in proceeding with the MOD development, right?
Title: Re: Users Online Today Mod
Post by: symon on October 10, 2007, 05:21:10 AM
Who knows...the point is this mod has been deserted! And it's very popular. But the functionality is never going to get better when the attitude is "it works...now get on with it".

This is one of the most popular mods and it's development is not going to grow.

Mods that don't/can't evolve aren't much use.
Title: Re: Users Online Today Mod
Post by: christicehurst on October 10, 2007, 06:24:30 AM
Well, I'm sure I can find someone who would take over this mod.
Title: Re: Users Online Today Mod
Post by: Paracelsus on October 10, 2007, 06:40:26 AM
Quote from: symon on October 10, 2007, 05:21:10 AM
Who knows...the point is this mod has been deserted! And it's very popular. But the functionality is never going to get better when the attitude is "it works...now get on with it".

This is one of the most popular mods and it's development is not going to grow.

Mods that don't/can't evolve aren't much use.

Jesus, why are you being so dramatic? I'm pretty sure that someone will take it, since it's so popular.
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on October 10, 2007, 06:46:06 AM
@symon

what whould you like to see then,... it's just a little bar wich shows who where online that day... nothing more nothning less....
Title: Re: Users Online Today Mod
Post by: symon on October 10, 2007, 06:51:58 AM
QuoteJesus, why are you being so dramatic? I'm pretty sure that someone will take it, since it's so popular.

How's that dramatic? Your responses are harsh and dramatic! Response 742 I may add!

Stop insulting people who post for help...I'm sure it's not the SMF way.

Quote from: The Burglar! on October 10, 2007, 06:46:06 AM
@symon

what whould you like to see then,... it's just a little bar wich shows who where online that day... nothing more nothning less....

See...you don't even know the mod. It's not just a little bar and why is progression so wrong? Showing a total of all guests online that day in addition to most online at once would be great. Why does suggestions pi$$ SMF off so much?

People just want help sorting this mod on other themes. What kind of crerten post here just to insult "why don't you just read it" [email protected]
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on October 10, 2007, 07:33:18 AM
well i have rewrite this mod for use on different skins or themes.... for the dutch community here at smf.... so i am beware of the mod and how it works.... i have here a little link for ya.... this one i have modified for default theme (standard) plus the classic theme......

if ya have an other theme you want it working on just tell so i can take a look at it....

http://www.yabb.nl/forum/index.php?topic=44820.msg75067#msg75067

or look at my own site here

http://www.teczone.nl/downloads/category.php?id=2
Title: Re: Users Online Today Mod
Post by: Paracelsus on October 10, 2007, 08:03:03 AM
Quote from: symon on October 10, 2007, 06:51:58 AM
QuoteJesus, why are you being so dramatic? I'm pretty sure that someone will take it, since it's so popular.

How's that dramatic? Your responses are harsh and dramatic! Response 742 I may add!

Stop insulting people who post for help...I'm sure it's not the SMF way.

Quote from: The Burglar! on October 10, 2007, 06:46:06 AM
@symon

what whould you like to see then,... it's just a little bar wich shows who where online that day... nothing more nothning less....

See...you don't even know the mod. It's not just a little bar and why is progression so wrong? Showing a total of all guests online that day in addition to most online at once would be great. Why does suggestions pi$$ SMF off so much?

People just want help sorting this mod on other themes. What kind of crerten post here just to insult "why don't you just read it" [email protected]


I don't understand all this aggressive stance... nobody here is pissed off and nobody is insulting you, just take it easy man...

Don't worry, someone will eventually follow this mod, since it's popular and lot's of people have it! (now, this isn't that hard to understand). As it is, this MOD serves its purpose 100% and doesn't need any more development right now.

Why don't we just wait a little longer for 2.0 and then people "upgrade" the MOD and add some new features to it? ;)
Title: Re: Users Online Today Mod
Post by: symon on October 10, 2007, 08:38:33 AM
Thanks Burglar...your a star. However I wasn't too clear as I have this working fine...I was just referring to other's treatment by some.

Paracelsus  ...saying "Jesus, why are you being so dramatic?" and patronizing people is out of order and I'm not going to take your bate. Because I comment on that does not give you right to condescend.

All I'm saying as far as development...why can't it be better and why does it have to stand still because you say so? Yes it works...but it could be even better. Nothing wrong with that fella :)

With all due respect ...you need to spend less time patronizing and more time helping. I've tried my best way back near the beginning of this thread. Telling people it's easy when they come to a support forum for help is disrespectful.
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on October 10, 2007, 08:52:14 AM
we are all here to help others with their problems or extend his/her needs for their forum ....
also everybody is an Volunteer so it can be take some time if your question is not answered...
and not everybody is an smf pro.... and i am not the original dev of the mod... i'll do things  like remodding just coz some dutch people... are afraid to ruine some stuff on there forums or even don't speak english at all....  ;D

cheers!
Title: Re: Users Online Today Mod
Post by: symon on October 10, 2007, 09:06:29 AM
What you do is impressive and way beyond my skills. It's very much appreciated from everyone...however much the help is :D

ps. My comments where not meant to cause issues   O:) :-*
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on October 10, 2007, 09:18:43 AM
youre welcome.... just ask if ya need someting  ;D
Title: Re: Users Online Today Mod
Post by: Paracelsus on October 10, 2007, 04:30:21 PM
Quote from: symon on October 10, 2007, 08:38:33 AM
Paracelsus  ...saying "Jesus, why are you being so dramatic?" and patronizing people is out of order and I'm not going to take your bate. Because I comment on that does not give you right to condescend.

(...)

With all due respect ...you need to spend less time patronizing and more time helping. I've tried my best way back near the beginning of this thread. Telling people it's easy when they come to a support forum for help is disrespectful.

You can keep on your borderline speech as long as you want... it doesn't affect me, I'm well vaccinated against it ;)

As for the MOD, I'm sure whoever has the chance to develop it, will absolutely do it. If nobody wants to do it, relax, it's not the end of the world. ;D
Title: Re: Users Online Today Mod
Post by: dxyy on October 10, 2007, 04:35:52 PM
I asked this before, but I still haven't received an answer. Is there a way to make this mod visible to guests? Seeing a long list of member names is a lot more effective than a simple number that I assume many guests do not even notice. :(

Also, I saw that someone else was interested in also having this mod keep track of how many guests accessed the forum in any given day. I'm also very interested in such functionality, and if anyone could offer some help in that area I would greatly appreciate it.

Thank you! :D
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on October 11, 2007, 09:20:05 AM
@Paracelsus

please don't be offensive here he said before
QuoteMy comments where not meant to cause issues

@hugodiaz

i'll look into it when i have a little spare time over....
Title: Re: Users Online Today Mod
Post by: Paracelsus on October 11, 2007, 09:58:17 AM
I wasn't being offensive... and my comments were not meant to cause any issues either.
Title: Re: Users Online Today Mod
Post by: dxyy on October 11, 2007, 10:17:02 PM
Quote from: The Burglar! on October 11, 2007, 09:20:05 AM
@hugodiaz

i'll look into it when i have a little spare time over....
Thanks, please let me know what you discover. :)

I really think it should be visible to guests, and I can't understand why it is not. :(
Title: Re: Users Online Today Mod
Post by: sunnyslp on October 13, 2007, 11:49:35 PM
superb mod :)  thnx for this

Title: Re: Users Online Today Mod
Post by: Jade Elizabeth on October 14, 2007, 12:15:20 AM
*butts into argument* <or is it over? lol
is there a way we can keep some sort of log on hand of the people who were online on such and such a day?
it would be good to check if people logged in on days i was away.

lol
Title: Re: Users Online Today Mod
Post by: cheesenub on October 16, 2007, 02:04:36 AM
Quote from: pirat3 on July 30, 2007, 11:20:03 PM
hi can anyone tell me what files i need to edit for aa new daamage?

I can't get this to work with AA New Damage either.

I made the changes to BoardIndex.template.php and there is no Stats.template.php for this theme.

Has anyone gotten it to work with AA New Damage? Any advice on fixing the code?
Title: Re: Users Online Today Mod
Post by: pibe86 on October 16, 2007, 11:12:45 PM
Quote from: snork13 on November 06, 2005, 05:54:53 PM
works great in 1.1rc1, thanks for sharing


-snork

sir, your signature helps me a lot, thanks
Title: Re: Users Online Today Mod
Post by: Jade Elizabeth on October 16, 2007, 11:20:58 PM
can someone answer my question too?
Title: Re: Users Online Today Mod
Post by: cheesenub on October 16, 2007, 11:31:18 PM
Quote from: pibe86 on October 16, 2007, 11:12:45 PM
Quote from: snork13 on November 06, 2005, 05:54:53 PM
works great in 1.1rc1, thanks for sharing


-snork

sir, your signature helps me a lot, thanks

Hmm, yeah. Too bad it doesn't help for the AA New Damage theme.

Does anyone have it working for this theme yet?
Title: Re: Users Online Today Mod
Post by: Bigguy on October 17, 2007, 01:19:26 AM
reading the .xml file that comes with the mod will enable you to put the edits into that theme so it will work.
Title: Re: Users Online Today Mod
Post by: Bigguy on October 17, 2007, 01:20:39 AM
@ Alundra: Do you mean about keeping a log file of logged on users. ???
Title: Re: Users Online Today Mod
Post by: cheesenub on October 17, 2007, 02:37:25 AM
Quote from: Bigguy on October 17, 2007, 01:19:26 AM
reading the .xml file that comes with the mod will enable you to put the edits into that theme so it will work.

I read the xml file and edited the code manually but I still get errors.

Can anyone confirm that the edits work for AA New Damage?
Title: Re: Users Online Today Mod
Post by: dxyy on October 17, 2007, 08:10:25 AM
Quote from: hugodiaz on October 10, 2007, 04:35:52 PM
I asked this before, but I still haven't received an answer. Is there a way to make this mod visible to guests? Seeing a long list of member names is a lot more effective than a simple number that I assume many guests do not even notice. :(

Also, I saw that someone else was interested in also having this mod keep track of how many guests accessed the forum in any given day. I'm also very interested in such functionality, and if anyone could offer some help in that area I would greatly appreciate it.

Thank you! :D
Ok, since I haven't really heard anything about this as yet:

If I pay can someone make this mod visible to guests and also possibly keep track of the number of guests who visited?

I can only use paypal, and I prefer to deal with trusted and established members. What I mean is members who have been on this forum for some time already etc. :)

Thanks for your time.

PS: I am still using 1.1.3 and if you do a good job on this you can expect future work to help me move to 2.0 eventually. ;)
Title: Re: Users Online Today Mod
Post by: sunnyslp on October 17, 2007, 01:11:14 PM
hi all

i have a small problem,the mod installed fine without needing a manual edit

but it doesn't show the text "users logged in today",it just displays the users who logged in today without the title :(

i installed this on another theme via manual edit and got the exact same problem i resolved this by placing Modifications.english.php with the code required by mod in the languages folder.

but now i am using theme "mystic jade" ,in which there isn't a language folder(tried creating folder and copy file,no luck) kindly help me out
Title: Re: Users Online Today Mod
Post by: Jade Elizabeth on October 17, 2007, 05:21:14 PM
Quote from: Bigguy on October 17, 2007, 01:20:39 AM
@ Alundra: Do you mean about keeping a log file of logged on users. ???

i wanna log, kinda like the moderation log in how it works, that updates each night when the online today mod resets.
so i can view it, and keep as many days as i want and clean it out, or just clean certain days out and leave the rest (like if suddenly the online totals broken i know who helped make it happen and could give them some sort of reward or award).
so basically i just want it recorded somewhere in an editable log lol
Title: Re: Users Online Today Mod
Post by: Jade Elizabeth on October 17, 2007, 09:40:16 PM
it would be great if it could show average logins vs average logins that posted per day too

(i have enhanced forum stats lol)
Title: Re: Users Online Today Mod
Post by: PNatal on October 20, 2007, 04:26:55 PM
I just tried this mod for SMF 1.1.4 and I keep getting this error in the admin error log:


8: Undefined index: uot_users_online_today
File: /afs/ist.utl.pt/users/5/0/ist146950/web/forums/Themes/default/BoardIndex.template.php (main sub template - eval?)
Line: 407


The error also occurs on line 410.
It seems that 'uot_users_online_today' is not recognized in this file...

Help anyone?
Thanx
Title: Re: Users Online Today Mod
Post by: Carceri on October 24, 2007, 05:32:20 AM
Quote from: symon on October 10, 2007, 05:21:10 AM
Who knows...the point is this mod has been deserted! And it's very popular. But the functionality is never going to get better when the attitude is "it works...now get on with it".

This is one of the most popular mods and it's development is not going to grow.

Mods that don't/can't evolve aren't much use.

Let me answer this one.

This is a small mod that does not alter the database, and only affects a few files. It shows a list of users online during the day... no more, no less. This is the feature I was missing, and hence I created this mod. Yes, some people would like to have additional features, but some of the features people request (e.g. make the list available to guests) are possible with a small code edit, and it is described in this thread.

The mod is not deserted. If bugs are discovered I'll try to fix them, but from my point of view, this mod does what it is supposed to, and I have no current interest (or time) in adding a bunch of other features.

Just because there isn't a new version out every second day, doesn't mean that the mod doesn't work or is full of bugs. I actually appreciate software that I can just install and have it working, without having to look for a new version that fixes bugs every week or so.

Actually I am surprised that so many people have assumed that since I don't visit this forum, I have left this mod alone, yet I have not received a single PM asking me that question. PM's are forwarded to my e-mail address, so I do read them :)

But yes... if SMF 2.0 does not have this feature built in, I will make this mod compatible with 2.0 as well.
Title: Re: Users Online Today Mod
Post by: cheesenub on October 24, 2007, 10:10:59 AM
How about helping me get this working for the AA New Damage template that I'm working with?
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on October 24, 2007, 01:05:57 PM
search in your boardindex.template.php for the following code


echo '
<br />
', $context['show_stats'] && !$settings['show_sp1_info'] ? '<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>
<tr>
<td class="windowbg2" width="100%">
<span class="middletext">
', $txt['most_online_today'], ': <b>', $modSettings['mostOnlineToday'], '</b>.
', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';


right after it place the following code
before this line // If they are logged in, but SP1 style information is off... show a personal message bar.


// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


that's for AA Damage !!
Title: Re: Users Online Today Mod
Post by: cheesenub on October 24, 2007, 02:04:08 PM
Thank you so much!

That finally worked.
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on October 24, 2007, 02:31:45 PM
 ;D you're welcome....
Title: Re: Users Online Today Mod
Post by: camaroman1203 on October 24, 2007, 07:06:51 PM
I am using Slickpro: Graphite theme.  I have a problem with my "users online today" mod.

I am not getting the top bar that says "Users Online Today"  it is just showing the numbers and names without the text. 

Anyone have any ideas of why?  I have tried it on a fresh install and it works, shows the divider bar,  but not on my site.  the only mods i have are BBC google video, BBC youtube video, and flashchat integration.  I can't figure out why the little header above it won't show up.
Title: Re: Users Online Today Mod
Post by: Jade Elizabeth on October 24, 2007, 07:50:31 PM
still want a log


can we remove the visible/hidden thing, so users dont know hidden users were online?
Title: Re: Users Online Today Mod
Post by: camaroman1203 on October 24, 2007, 08:12:45 PM
it won't show the title "Users Online Today"  even in the default theme--no header.
Title: Re: Users Online Today Mod
Post by: camaroman1203 on October 24, 2007, 08:45:31 PM
It appears that it may be due to FlashChat integration. 

Has anyone else had this problem that has FlashChat integrated.  Where it doesn't show the header for the Users Online Today above the box.  It just makes a box after Users Online with the members in it.
Title: Re: Users Online Today Mod
Post by: camaroman1203 on October 24, 2007, 09:46:00 PM
FOUND THE PROBLEM!!

It was in  Modifications.english.php

<?php
// Version: 1.1; Modifications

$txt['googlevid'] = 'Googlevideo';

$txt['youtube'] = 'YouTube';


// --- Begin FlashChat Integration ---
$txt['fc_chat'] = 'Chat';
$txt['fc_flashchat'] = 'FlashChat';
$txt['fc_flashchat_settings'] = 'FlashChat Integration Settings';
$txt['fc_in_chat'] = 'in Chat';
$txt['fc_not_found'] = 'FlashChat does not appear to be installed!';
$txt['fc_no_guests'] = 'Sorry, guests aren\'t allowed to use the chat!';
$txt['fc_private_room'] = '<i>private room</i>';
$txt['fc_users_online'] = 'Users currently in chat';
// For 'Who's Online' page
$txt['whoall_chat'] = 'In the <a href="' $boardurl '?action=chat">Chatroom</a>';

// Settings for admin panel
$txt['fc_height2'] = 'Height';
$txt['fc_inForum'] = 'Display chat window "inside" forum?';
$txt['fc_newWindow'] = 'Open chat in new window?';
$txt['fc_showUsers'] = 'Display Users in Chat at top of forum?';
$txt['fc_showUserCount'] = 'Show number of users on Chat button?';
$txt['fc_size_desc'] = 'The height and width may be an integer (eg. 600 for 600 pixels) or a percentage (eg. a width of 100% will fill the whole screen horizontally)<br /><strong>Note:</strong> If "' $txt['fc_inForum'] . '" is turned on, please do not use a percentage for the height. It will not work correctly!';
$txt['fc_width'] = 'Width';
// --- End FlashChat Integration ---$txt['uot_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';

?>



As you can see when you have FlashChat Integrated in your "Modifications.english.php" file you will see that code, if you install this mod after integrating the chat.

So if you are installing this after FlashChat
Change this// --- End FlashChat Integration ---$txt['uot_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';


To This
// --- End FlashChat Integration ---
$txt['uot_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';


As you can see it adds the variable after the //End FlashChat Integration--- line which makes it seem like it's not there.  Very simple fix, just took me a while to find it.
Title: Re: Users Online Today Mod
Post by: spanishsilver on October 25, 2007, 12:15:05 PM
I keep getting this problem when I install this mod. The top of the forum just has a bunch of code and the font size changes. here is a screen shot.
Title: Re: Users Online Today Mod
Post by: SA™ on October 29, 2007, 09:55:41 PM
in your theme directory languages find Modifications.english.php find ?>
near the bottom and cut and past it right at the bottom
Title: Re: Users Online Today Mod
Post by: eleven0 on November 03, 2007, 10:29:43 PM
How can I change 24 hours to something else?
Title: Re: Users Online Today Mod
Post by: dxyy on November 04, 2007, 01:35:54 AM
Quote from: Eleven0 on November 03, 2007, 10:29:43 PM
How can I change 24 hours to something else?
Yes, and is it possible to have it be the 'last 24 hours' instead of just from 12AM of the day. For example, if you go to the forum at 1AM, it will only show the users who were active between 12 and 1AM.

Personally I think it would be better if it could be the last 24 hour period, instead of 'today'

Does anyone know how to achieve this?

Thank you in advance! :)
Title: Re: Users Online Today Mod
Post by: SA™ on November 04, 2007, 04:56:36 AM
there is a mod users online in the last tweny four hours its old tho i have it on my forum i had to mauly install it tho


http://custom.simplemachines.org/mods/index.php?mod=479
Title: Re: Users Online Today Mod
Post by: VegaTheChosen on November 05, 2007, 10:08:13 PM
ive added this mod to my forum
and it worked with everything but  B l a c k - R a i n V.2 by C r i p ~ theme
can anyone point me in the direction of getting this to show on this particular theme?
thanks
Title: Re: Users Online Today Mod
Post by: VegaTheChosen on November 07, 2007, 02:47:45 PM
Quote from: VegaTheChosen on November 05, 2007, 10:08:13 PM
ive added this mod to my forum
and it worked with everything but  B l a c k - R a i n V.2 by C r i p ~ theme
can anyone point me in the direction of getting this to show on this particular theme?
thanks

any help?
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on November 07, 2007, 04:53:20 PM
BoardIndex.template.php search for this

', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';


not every theme has that inside it don't know if you theme does

add after that code


// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


success  ;D
Title: Re: Users Online Today Mod
Post by: Jade Elizabeth on November 07, 2007, 05:49:45 PM
how do we hide the hidden users from being "counted"
Title: Re: Users Online Today Mod
Post by: VegaTheChosen on November 07, 2007, 11:00:25 PM
Quote from: The Burglar! on November 07, 2007, 04:53:20 PM
BoardIndex.template.php search for this

', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';


not every theme has that inside it don't know if you theme does

add after that code


// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


success  ;D


the code you gave worked!
thank you!
I didnt have the script that you posted in the boardindex but i found the spot
thanks again
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on November 07, 2007, 11:10:32 PM
you're welcome  ;D
Title: Re: Users Online Today Mod
Post by: elliatt on December 03, 2007, 09:39:26 AM
I've installed this mod on 1.1.4 but it does not show up.

It installed with no problem or errors.

I'm using the default theme/skin and no other mods are installed.

Any suggestions?
Title: Re: Users Online Today Mod
Post by: Kimmie on December 04, 2007, 02:30:12 PM
Quote from: The Burglar! on November 07, 2007, 04:53:20 PM
BoardIndex.template.php search for this

', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';


not every theme has that inside it don't know if you theme does

add after that code


// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


success  ;D


I added this to that template and for the most part it works great. Is there a code I can add so that it will also show the heading " Users Logged In Today" (like the mod does on the default theme)? Or just show that heading instead of the ":2 ( :2 :0)" part?

(http://www.fileupyours.com/files/138165/usersonline.jpg)

Thanks in advance. :)
Title: Re: Users Online Today Mod
Post by: Stargater59 on December 04, 2007, 02:55:13 PM
Kimmie, in the default theme directory go to

languages/Modifications.english.php

and add:

$txt['uot_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';


And in stats.english.php add (unless it was added already):


$txt['users_online_today'] = 'Online Today';
$txt['num_hits'] = 'Total page views';
$txt['average_hits'] = 'Average page views per day';


That should work for any theme. Unless the theme uses it's own language files. 
Title: Re: Users Online Today Mod
Post by: Kimmie on December 04, 2007, 04:13:23 PM
In the languages/Modifications.english.php in the default theme, this is what was already there:

<?php
// Version: 1.1; Modifications
$txt['uot_users_online_today']='Users Logged In Today';
$txt['uot_yesterday']='Yesterday at ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visible';
$txt['uot_hidden']='Hidden';

?>


(looks the same so I didnt change anything there).

In the stats.english.php file, I have this

<?php
// Version: 1.1; Stats

$txt[888] = 'Most Online';

$txt['smf_stats_1'] = 'Statistics Center';
$txt['smf_stats_2'] = 'General Statistics';
$txt['smf_stats_3'] = 'Top 10 Posters';
$txt['smf_stats_4'] = 'Top 10 Boards';
$txt['smf_stats_5'] = 'Forum History (using forum time offset)';
$txt['smf_stats_6'] = 'Date (yyyy/mm/dd)';
$txt['smf_stats_7'] = 'New Topics';
$txt['smf_stats_8'] = 'New Posts';
$txt['smf_stats_9'] = 'New Members';
$txt['smf_stats_10'] = 'Page views';
$txt['smf_stats_11'] = 'Top 10 Topics (by Replies)';
$txt['smf_stats_12'] = 'Top 10 Topics (by Views)';
$txt['smf_stats_13'] = 'Monthly Summary';
$txt['smf_stats_14'] = 'Most Online';
$txt['smf_stats_15'] = 'Top Topic Starters';
$txt['smf_stats_16'] = 'Most Time Online';
$txt['smf_stats_17'] = 'Best Karma';
$txt['smf_stats_18'] = 'Worst Karma';
$txt['stats_more_detailed'] = 'more detailed &raquo;';

$txt['average_members'] = 'Average registrations per day';
$txt['average_posts'] = 'Average posts per day';
$txt['average_topics'] = 'Average topics per day';
$txt['average_online'] = 'Average online per day';
$txt['users_online'] = 'Users Online';
$txt['gender_ratio'] = 'Male to Female Ratio';
$txt['users_online_today'] = 'Online Today';
$txt['num_hits'] = 'Total page views';
$txt['average_hits'] = 'Average page views per day';

$txt['smf_news_1'] = 'comment';
$txt['smf_news_2'] = 'comments';
$txt['smf_news_3'] = 'Write Comment';
$txt['smf_news_error2'] = 'You cannot specify a board that doesn\'t allow guests.  Please check the board ID before trying again.';
$txt['xml_rss_desc'] = 'Live information from ' $context['forum_name'];

?>




All those files seem to be there. Does anything look incorrect in those? I had originally added the user online mod while I still had the default theme up but when I changed the theme to a new one, that feature no longer worked so I added that code to the board template.
Title: Re: Users Online Today Mod
Post by: Stargater59 on December 04, 2007, 04:32:35 PM
Well.. if the text strings are in Modifications.english.php, and you've made the appropriate edits to the theme you're using. The text should show up..
Title: Re: Users Online Today Mod
Post by: Kimmie on December 04, 2007, 05:08:09 PM
When I changed to the new theme, that info didnt appear - so I added this code, which allows it to work, It just has the #'s (:2 (:2 :0) instead of the "Users Logged In Today" text.


// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


Is there a way to just adjust the above code to add the Users Logged In Today text as well? Or perhaps change the code to where it says that "instead" of the numbers?
Title: Re: Users Online Today Mod
Post by: TrueSatan on December 04, 2007, 09:09:29 PM
Quote from: wdm2005 on November 04, 2007, 04:56:36 AM
there is a mod users online in the last tweny four hours its old tho i have it on my forum i had to mauly install it tho


http://custom.simplemachines.org/mods/index.php?mod=479

If you look at the support topic for that mod you'll find I've updated it and added two derivative mods with different time periods.
Title: Re: Users Online Today Mod
Post by: Stargater59 on December 04, 2007, 09:39:42 PM
Quote from: Kimmie on December 04, 2007, 05:08:09 PM
When I changed to the new theme, that info didnt appear - so I added this code, which allows it to work, It just has the #'s (:2 (:2 :0) instead of the "Users Logged In Today" text.


// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


Is there a way to just adjust the above code to add the Users Logged In Today text as well? Or perhaps change the code to where it says that "instead" of the numbers?

You could. But I believe it's better to do it the other way. What theme are you using?
Title: Re: Users Online Today Mod
Post by: Kimmie on December 05, 2007, 12:18:03 AM
Right now I am using this one:

http://custom.simplemachines.org/themes/index.php?lemma=411

EDIT- I changed themes to a different one and it works fine. Must be something wrong with the compatability of it with that other theme.
Title: Re: Users Online Today Mod
Post by: Stargater59 on December 05, 2007, 01:45:02 AM
There's your problem.

That theme uses its own language files. Meaning, instead of having to edit the default theme's Modifications.english.php, you needed to add the text strings to blue_lt/languages/Modifications.english.php
Title: Re: Users Online Today Mod
Post by: Kimmie on December 05, 2007, 12:36:46 PM
Thanks very much for all your help!  :)
Title: Re: Users Online Today Mod
Post by: chrishicks on December 06, 2007, 09:08:55 AM
is there a way to remove all of the "hidden" references in this or is it possible that this could be set for only admin/mods to view? I have myself and a few mods who have hidden accounts so we can watch what goes on at the board but seeing the hidden references I think is killing our snooping.
Title: Re: Users Online Today Mod
Post by: Jade Elizabeth on December 06, 2007, 12:01:34 PM
http://www.simplemachines.org/community/index.php?topic=201301


see johnyb's post (it hides admin only i think, havent tested it for others yet lol)
Title: Re: Users Online Today Mod
Post by: NewPie on December 15, 2007, 07:12:08 PM
Quote from: tick on April 21, 2007, 08:46:44 AM
Quote from: a.D on April 20, 2007, 08:12:14 PM
This installed fine on the forum, but it doesn't display on the Dilber theme I'm using.

Can someone help?


I posted this a few pages back.  This is how to make it work with dilber mc.     http://www.simplemachines.org/community/index.php?topic=55513.msg1001561#msg1001561

Unfortunately, I have the same problem: this great mod isn't working on DilberMC theme.
But this advice doesn't work: I can't find the needed code in index.template.php. :-[ (not even a part, "like modsettings") and modparser won't help.

Using SMF 1.1.4
Title: Re: Users Online Today Mod
Post by: growwl on December 30, 2007, 03:35:12 AM
I am using the Usersonpinetoday mod on my external site via ssi, but it won't count the users correctly. it looks like they appear only hours after visiting the site or some users do completely fail to be counted although they have been there.
is that a logincookie problem or something else?
Title: Re: Users Online Today Mod
Post by: octap on December 31, 2007, 12:27:35 PM
Quote from: The Burglar! on November 07, 2007, 04:53:20 PM
BoardIndex.template.php search for this

', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';


not every theme has that inside it don't know if you theme does

add after that code


// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


success  ;D


This worked for me also.
Theme: ApolloBB

Thank you!

EDIT: I was quick to say that it worked. The problem I have is strange I think. The text "     
Total: 59 (Visible: 59, Hidden: 0)" is only vewed by me (admin). Global Mods and members see this: ": 59 (: 59, : 0)"

Any help/idea ?

EDIT2: We ask from our members to search before open new posts and ask things...I should have looked more arround before posting.
Everything is ok for me now...I added the extra lines in the Modifications.english.php
Title: Re: Users Online Today Mod
Post by: Muhammad Asad on January 04, 2008, 01:20:19 AM
I have outline theme installed...What code modifications are needed to make this mod functional for that theme too?

I am attaching my BoardIndex.template.php, so if someone can tell me where to insert or just edit it and upload back?
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on January 05, 2008, 02:20:56 AM
well did make the edit for ya look if this works for ya
maybe you need to edit the language file modifications.yourlanguage.php compare it with modifications.english.php
Title: Re: Users Online Today Mod
Post by: Looking on January 07, 2008, 11:29:03 AM
Great mod. What about a record of unique guests that have visited the site in 24 hours?
Title: Re: Users Online Today Mod
Post by: gtron on January 27, 2008, 09:11:46 AM
is there a way to display to guests?

im sorry i dont have time to read this entire thread because im so busy today. :(
Title: Re: Users Online Today Mod
Post by: Kirok on February 09, 2008, 05:38:17 PM
Hi there!

I just installed this great mod (thank you), and was wondering how to properly display the text "Users Logged In Today" in the 'Info Center'.  All it shows now is a semi-colon, the number of users, and that's it.  It doesn't specify what it is exactly... just all the user's names.

Any ideas or suggestions on how to edit that area in the 'Info Center'?

Thanks!
Kirok  :)

Title: Re: Users Online Today Mod
Post by: crustybum on February 13, 2008, 07:48:08 AM
Cant seem to get this mod to work on the "classic" theme, have tried using the parsar, but it asks me to find code that isnt there on the classic boardindex.
Anyone?

Chris
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on February 13, 2008, 11:06:15 AM
try this http://www.simplemachines.org/community/index.php?topic=123350.msg886740#msg886740
Title: Re: Users Online Today Mod
Post by: Powerbob on February 20, 2008, 04:08:31 AM
Quote from: Carceri on October 24, 2007, 05:32:20 AM
Quote from: symon on October 10, 2007, 05:21:10 AM
Who knows...the point is this mod has been deserted! And it's very popular. But the functionality is never going to get better when the attitude is "it works...now get on with it".

This is one of the most popular mods and it's development is not going to grow.

Mods that don't/can't evolve aren't much use.

Let me answer this one.

This is a small mod that does not alter the database, and only affects a few files. It shows a list of users online during the day... no more, no less. This is the feature I was missing, and hence I created this mod. Yes, some people would like to have additional features, but some of the features people request (e.g. make the list available to guests) are possible with a small code edit, and it is described in this thread.

The mod is not deserted. If bugs are discovered I'll try to fix them, but from my point of view, this mod does what it is supposed to, and I have no current interest (or time) in adding a bunch of other features.

Just because there isn't a new version out every second day, doesn't mean that the mod doesn't work or is full of bugs. I actually appreciate software that I can just install and have it working, without having to look for a new version that fixes bugs every week or so.

Actually I am surprised that so many people have assumed that since I don't visit this forum, I have left this mod alone, yet I have not received a single PM asking me that question. PM's are forwarded to my e-mail address, so I do read them :)

But yes... if SMF 2.0 does not have this feature built in, I will make this mod compatible with 2.0 as well.

Up to now it does not, and I'm sure all charter members would welcome and use it :)

Thanks

Bob
Title: Re: Users Online Today Mod
Post by: Sabre™ on February 24, 2008, 03:46:22 PM
Quote from: The Burglar! on November 07, 2007, 04:53:20 PM
BoardIndex.template.php search for this

', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';


not every theme has that inside it don't know if you theme does

add after that code


// Users online today

echo '
<tr>
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';


success  ;D

Hello.
I tried the above code.
And it works with the theme invazion.
But it has pushed everything to the right of the screen
(http://img91.imageshack.us/img91/8417/pushedml0.png)

Any ideas peeps?
My board index template is attached if you would like to have a look.

Thank You in advance :)
Title: Re: Users Online Today Mod
Post by: ranKoto on February 27, 2008, 02:41:12 AM
Hi all,

I just installed this mod, and was wondering how to display the Most Logged In User recorded for a day, you know, some thing like Most Online Ever, but its The Most Logged User Ever

Thanks!
Title: Re: Users Online Today Mod
Post by: Trulyana on February 29, 2008, 07:08:44 PM
I have this mod installed, and notice that it only shows Users Logged In Today, when I log in. It is not viewable to guests, and I would like to make it so. How would you go on about making that happen?
Title: Re: Users Online Today Mod
Post by: Herman's Mixen on February 29, 2008, 08:40:28 PM
sabre take a look at this line

<td class="windowbg" width="20" valign="middle" align="center">


and play a little with the aligments valign="middle|left|right"  ;)
or try just one of the package parsers and then only the theme edits !!

one can be found in my sig
Title: Re: Users Online Today Mod
Post by: Sabre™ on March 02, 2008, 12:08:30 AM
Thanks for the response Burglar.
I tried playin with the alignment..   No glory.
Was tired when I typed the above comment, and forgot to mention that I had earlier tried installing with the Package parser.
Its the same installation as above, with the added changes to the themes stats template.
My theme doesnt have this template.
Theme = invazion.
I had a similar prob with another mod a while ago, but have forgotten what I had changed :-\
Hopefully someone will enlighten me :)

Cheers
Title: Re: Users Online Today Mod
Post by: Sabre™ on March 02, 2008, 05:04:14 PM
SOLVED. :D

Thanks to nokonium for his assistance.
This is for people that are also using the invazion theme.

Quote from:  nokoniumThe primary problem is that the code for Users online today has already been added to the Boardindex.template but to be able to use the code it has to be enabled in the theme support for different mods, unfortunately this is missing so the correct code (different to that inserted into the default/boardindex.template) does not show. All I have done is comment out the 'if' (including closing '}' ) that checks for this mod being enabled in the settings.

This is what I altered

Find

// Users online today
if(!empty($settings['use_usersonlinetoday']))
{
echo '
<tr>
<td class="catbg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';

  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';

// Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
echo '<br />', implode(', ', $context['list_users_online_today']);

echo '
<br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';
}


Replace with

// Users online today
//if(!empty($settings['use_usersonlinetoday']))
//{
echo '
<tr>
<td class="catbg" colspan="2">', $txt['uot_users_online_today'], '</td>
</tr><tr>
<td class="windowbg" width="20" valign="middle" align="center">
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today'], '" border="0" />
</td>
<td class="windowbg2" width="100%">';

echo '
<div class="smalltext">';

  echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';

  if (!$context['user']['is_guest'])
  echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today