$context['users_online_today'] = array();
$context['list_users_online_today'] = array();
$context['num_buddies'] = array();
Quote from: thetzfreak on November 06, 2005, 09:55:34 PMIf 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.
Do I have to do the custom editing thing for my theme even after you updated it now?
$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.
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 :)
Quote from: Tippmaster on November 07, 2005, 05:06:07 PMNot 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.
since the problem is that their names are italicised, then removeing <i></i> will work..it's like the only fix.
Quote from: Libo on November 07, 2005, 07:19:30 PMIt's on my TODO list :)
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?
Quote from: 1948Pal on November 07, 2005, 10:39:11 PMI 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.
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?
Quote from: Libo on November 08, 2005, 11:38:38 AMThe 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 :)
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.
Quote from: Hachi on November 08, 2005, 03:27:58 PMI'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?
2: in_array(): Wrong datatype for second argument
File: /home/fearncou/public_html/forum/Sources/BoardIndex.php
Line: 271
Quote from: 1948Pal on November 07, 2005, 10:39:11 PMfasan took his mod off the list
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?
Quote from: galgoz on November 09, 2005, 06:14:54 PMCould 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.
$is_buddy = in_array($row['ID_MEMBER'], $user_info['buddies']);
$is_buddy = in_array($row['ID_MEMBER'], $user_info['buddies']);
if ($is_buddy)
{
$link = '<b>' . $link . '</b>';
}
'is_buddy' => $is_buddy,
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?
Quote from: electrohome88 on November 11, 2005, 03:40:16 PMSure, 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?
think you could make it possible for this to appear on the [stats] page as "most online users today" ?
$frag = explode('-', strftime('%Y-%m-%d', forum_time(false)));
$midnight = mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]);
$frag = explode('-', strftime('%Y-%m-%d', time()));
$midnight = forum_time(false, mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]));
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?
Quote from: jonc on November 16, 2005, 12:14:13 AMOkay, 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 :)
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!
Quote from: Juggler on November 16, 2005, 05:21:41 AMIt is back in the latest RC version as "Total Users Online Today"
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!
Quote from: Libo on November 16, 2005, 04:46:44 PMThen 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.
fix the forum time difference between server time. in next version plz
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...
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...
Quote from: jonc on November 17, 2005, 08:54:30 PMI 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.
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.
Quote from: Carceri on November 18, 2005, 02:12:34 AMQuote 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...
QuoteAlso that you are patching the files that are actually served by the webserver.
Quote from: Libo on November 18, 2005, 11:49:05 AMIf 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.QuoteAlso that you are patching the files that are actually served by the webserver.What does that mean?
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?
Quote from: Libo on November 18, 2005, 02:57:50 PMOne 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.
Only question when is stats center gonna be working?
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'];
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 :-
Quote from: Jorg40 on November 19, 2005, 11:01:48 AMApparently something has changed BoardIndex.template.php and my mod is only tested agains the original file. You can probably still apply the mod manually.
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?
Quote from: Jorg40 on November 19, 2005, 01:59:15 PMhttp://www.simplemachines.org/community/index.php?topic=34526.0
How to install it manually?
Quote from: Jorg40 on November 19, 2005, 01:59:15 PMThis mod does not support SMF 1.0.5
I use SMF 1.0.5
Quote from: Jorg40 on November 19, 2005, 03:57:52 PMIt is written on the download page for the mod... 1.1 RC1
What version does it support then?
Quote from: Jorg40 on November 19, 2005, 04:51:03 PMYou 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.
How does I change the path of the install to anther skin?
Or do I have to install it manually then?
Quote from: Carceri on November 19, 2005, 12:05:03 PMQuote 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.
Quote from: FaSan on November 28, 2005, 03:12:19 AMThanks :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.
Great Mod ! and Great idea :P :P :P
Quote from: Carceri on November 28, 2005, 05:02:33 AMQuote from: FaSan on November 28, 2005, 03:12:19 AMThanks :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.
Great Mod ! and Great idea :P :P :P
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
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
Quote from: Libo on December 04, 2005, 04:45:11 PM
Helios Multi premod doesn't work with rc1....
Quote from: Maycomb on December 11, 2005, 10:29:57 PM
This may sound stupid, but where do you install this to?
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?
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?
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. ::)
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
mysql_free_result($result_boards);
// 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']);
$context['online_today'] = (int) $context['online_today'];
// 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);
<a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
</div>
</td>
</tr>';
// 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>';
<td nowrap="nowrap">', $txt['users_online_today'], ':</td>
<td align="right">', $context['online_today'], '</td>';
<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>';
?>
$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 ';
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?
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?
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?
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
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.
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
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
Quote from: RoarinRow on December 28, 2005, 06:24:02 PMQuote from: Stuart on December 28, 2005, 06:13:47 PMQuote 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:Code Select8: Undefined index: 158bis
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Themes/safblue105/BoardIndex.template.php (eval?)
Regel: 362Code Select8: 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';
Quote from: Stuart on December 28, 2005, 06:48:16 PMQuote from: RoarinRow on December 28, 2005, 06:24:02 PMQuote from: Stuart on December 28, 2005, 06:13:47 PMQuote 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:Code Select8: Undefined index: 158bis
Bestand: /data/members/paid/o/r/orisit.nl/htdocs/www/astmaforum/Themes/safblue105/BoardIndex.template.php (eval?)
Regel: 362Code Select8: 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
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.
Quote from: RoarinRow on December 29, 2005, 02:36:00 AMQuote 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.
Quote from: fresnolady on December 30, 2005, 12:27:53 AMQuote from: RoarinRow on December 29, 2005, 02:36:00 AMQuote 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 :(
Quote from: RoarinRow on December 30, 2005, 12:46:19 AMQuote from: fresnolady on December 30, 2005, 12:27:53 AMQuote from: RoarinRow on December 29, 2005, 02:36:00 AMQuote 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>';
Quote$yesterday = $userday == $loginday ? '' : $txt['uot_yesterday'];
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
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 :(
Quote from: SpyDie on January 05, 2006, 09:56:11 AMQuote 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.
Quote from: RoarinRow on January 05, 2006, 01:21:58 PMThx! Work's fine :)
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.
Quote from: Webster on January 05, 2006, 04:28:52 PMQuote from: RoarinRow on January 05, 2006, 01:21:58 PMThx! Work's fine :)
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.
Quote from: RoarinRow on January 05, 2006, 04:32:37 PMQuote from: Webster on January 05, 2006, 04:28:52 PMQuote from: RoarinRow on January 05, 2006, 01:21:58 PMThx! Work's fine :)
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.
Welcome! ;D
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.
Quote from: dustrho on January 08, 2006, 09:11:27 PMQuote 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.
Quote from: Gargoyle on January 08, 2006, 09:25:19 PMAre you using verion 1.3.1? 1.3.0 is for RC1 only?
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
Quote from: Furvert on January 11, 2006, 11:46:15 PMAs said it sorts by last online, and it will continue to do so :)
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.
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 ';
0 Guests, 1 User Users active in past 15 minutes: member2 | |
----------------- end tr ---------------- | |
online.gif | Logged In Today: 3 member1, member2, member3 |
----------------- end tr ---------------- | |
Most Online Today: ... Most Online Ever: ... | |
----------------- end tr ---------------- |
Quote from: fivearts on January 20, 2006, 12:21:55 PM
Is it possible to include number of Guests? Like this...
Quote from: diegolyanky on January 21, 2006, 11:09:31 AM
Is not corrupted, try with Windows Extract or WinRar ...
Regards ;)
Quote from: Carceri on January 21, 2006, 06:16:16 AMQuote 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.
Quote from: kai920 on January 21, 2006, 11:40:22 AM
I'm using Winrar! and get "Unexepcted end of archive" ::)
Quote from: mistermad on January 22, 2006, 10:30:22 AM
Or is there a way to develop the users online mod towards this?
if (!allowedTo('moderate_forum') && empty($row['showOnline'])) continue;
$context['users_online_today'] = array();
$context['list_users_online_today'] = array();
while ($row = mysql_fetch_assoc($result))
{
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.
:)
Quote from: Prasad007 on January 23, 2006, 06:24:03 AM
too bad it wont work on my non-default theme :(
Quote from: flapper on January 23, 2006, 11:47:18 AMDon't know. As I said the code was untested. Apparently it doesn't work :)
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
Quote from: kai920 on January 23, 2006, 11:42:26 PMHave 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?
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?
Quote from: kai920 on January 24, 2006, 04:34:13 AMCan 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...
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)
Quote from: Carceri on January 24, 2006, 05:04:01 AMQuote from: kai920 on January 24, 2006, 04:34:13 AMCan 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...
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)
Quote from: macgeek on January 28, 2006, 09:52:37 AM
didnt work for me. I using the saf blue theme.
Quote from: desistyle on January 28, 2006, 09:55:25 PM
well it used to work with smf 1.05
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 ?
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 :)
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.
Quote from: diegolyanky on January 30, 2006, 08:24:20 AMTry the 1.4.0 Beta 2 package I have just uploaded...
2° I like to modify this mod, but I don't know how to do it :(
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.
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.
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"?
Quote from: DemonicInfluence on February 16, 2006, 01:20:18 PM
boardindex.template.php
Quote from: alan s on February 16, 2006, 04:24:09 PMLet me guess. You are not using the default theme?
it dosent work for me at all??
Quote from: mcalan2001 on March 01, 2006, 08:28:13 AMCan 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.
I am using the default theme and have done a chmod 777 to all effected files.
Quote from: Bigguy on March 07, 2006, 08:57:50 PMAlright, is there anyone brave enough to write the code for this? I am not a programmer by any means...
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. :)
if($context['user']['is_admin'])
{
}
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???
// 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>';
Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).'
<td class="windowbg" width="20" valign="middle" align="center">
Most users online today: '.$modSettings['mostOnlineToday'].'
Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).' )
</span>
</td>
</tr>';
// 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>';
}
?>
Quote from: cbrchris on April 05, 2006, 10:43:48 AM
Thanks beemer! That worked great.
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
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!
Quote from: Backlash on April 19, 2006, 06:46:53 PM
i had a problem, and don't know how to fix it.Code Select
8: Undefined index: uot_hidden
Datei: /home/www/web23/html/board/Themes/default/BoardIndex.template.php (eval?)
Zeile: 419Code Select8: Undefined index: uot_visible
Datei: /home/www/web23/html/board/Themes/default/BoardIndex.template.php (eval?)
Zeile: 419Code Select
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??
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!
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
</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" />
</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" />
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>';
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>';
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>';
Quote from: beemer on April 04, 2006, 06:30:34 PM
You dont want to put it there
findCode Select
Most users online today: '.$modSettings['mostOnlineToday'].'
Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).' )
</span>
</td>
</tr>';
And replace everything below withCode Select
// 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>';
}
?>
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!
Quote from: beemer on April 04, 2006, 06:30:34 PM
You dont want to put it there
findCode Select
Most users online today: '.$modSettings['mostOnlineToday'].'
Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).' )
</span>
</td>
</tr>';
And replace everything below withCode Select
// 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>';
}
?>
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 ?
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?
Quote from: beemer on April 04, 2006, 06:30:34 PM
You dont want to put it there
findCode Select
Most users online today: '.$modSettings['mostOnlineToday'].'
Most users online ever: <b>'.$modSettings['mostOnline'].'</b> ( '.timeformat($modSettings['mostDate']).' )
</span>
</td>
</tr>';
And replace everything below withCode Select
// 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>';
}
?>
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?
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)
QuoteYou cannot download or install new packages because the Packages directory or one of the files in it are not writable!
Quote from: Bigguy on May 08, 2006, 11:46:23 PM
Is the backup folder inside the packages folder also chmodded to 777
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.
Quote from: geezmo on May 10, 2006, 08:19:35 AMYeah, like I previously posted, I was having the same problem.
at least, scott, something's showing in your forum. in mine (Default Theme, 1.1RC2), the mod was supposedly successfully installed but nothing appears.
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?
Quote from: L.G.S on May 10, 2006, 01:12:39 PMWhen 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?
Can I ever get some help for my problem please?
Quote from: DemonicInfluence on March 08, 2006, 11:37:39 AM
just make it so thatCode Selectif($context['user']['is_admin'])
{
is before the mod stuff in the boardindex.template.php of every theme.
Then at the end putCode Select}
Should work to only allow admins to see..
Quote from: scottws on May 09, 2006, 03:35:00 PM
Hmm...
It correctly works on the default theme:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Feac.forgiven5.com%2Fpictures%2Fusersonline.png&hash=34a832debabe4be834a7008f53a1b52105ac5aef)
But following beemer's instructions to get this mod working on Helios resulted in the same thing Vinspire^ is experiencing:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Feac.forgiven5.com%2Fpictures%2Fusersonline_helios.png&hash=ac796320fd9b8d971ca498d3507a3e0a3c70b679)
Quote from: scottws on May 10, 2006, 11:42:57 PM
Nope. No solution as of yet. I have to look at the code.
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?? ::)
Quote from: akulion on May 11, 2006, 11:47:05 PM"Just place the code..." What code are you referring to? Beemer's code?
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
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
Quote from: scottws on May 14, 2006, 09:40:50 AMQuote from: akulion on May 11, 2006, 11:47:05 PM"Just place the code..." What code are you referring to? Beemer's code?
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
// 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>';
Quote
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Feac.forgiven5.com%2Fpictures%2Fusersonline_helios.png&hash=ac796320fd9b8d971ca498d3507a3e0a3c70b679)
$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 ';
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 codeCode Select
$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 15, 2006, 04:19:30 PM
I am not seeing a Modifications.english.php file in 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 ';
?>
QuoteTotal: 2 (Visible: 2, Hidden: 0)
Quote2 users seen today
echo $context['num_users_online_today'], ' ', $context['num_users_online_today']
== 1 ? $txt['uot_user_online_today'] : $txt['uot_users_online_today'];
Quote from: scottws on May 16, 2006, 02:25:13 PMThis 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.QuoteTotal: 2 (Visible: 2, Hidden: 0)
instead of how it is now after doing the modification:Quote2 users seen today
Quote from: Carceri on May 17, 2006, 05:49:27 AMQuote from: scottws on May 16, 2006, 02:25:13 PMThis 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.QuoteTotal: 2 (Visible: 2, Hidden: 0)
instead of how it is now after doing the modification:Quote2 users seen today
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 ?
// 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>';
', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>';
]]></search>
<add><![CDATA[
Quote from: Carceri on May 17, 2006, 05:49:27 AMQuote from: scottws on May 16, 2006, 02:25:13 PMThis 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.QuoteTotal: 2 (Visible: 2, Hidden: 0)
instead of how it is now after doing the modification:Quote2 users seen today
Quote from: scottws on May 17, 2006, 08:37:09 AMQuote from: Carceri on May 17, 2006, 05:49:27 AMQuote from: scottws on May 16, 2006, 02:25:13 PMThis 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.QuoteTotal: 2 (Visible: 2, Hidden: 0)
instead of how it is now after doing the modification:Quote2 users seen today
Ok, well then does anyone have any idea how to get this properly working on the Helios theme?
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 ;)
$nowdate = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);
$midnight = time() - 86400;
$frag = explode('-', strftime('%Y-%m-%d', time()));
$midnight = forum_time(false, mktime(0, 0, 0, (int) $frag[1], (int) $frag[2], (int) $frag[0]));
$midnight = time() - 86400;
Quote from: Carceri on May 18, 2006, 07:20:56 AMQuote 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 findCode Select
$nowdate = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);
And replace withCode Select
$midnight = time() - 86400;
And in Stats.php findCode Select
$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 withCode Select
$midnight = time() - 86400;
Also edit Modifications.english.php to the appropriate text you want displayed
Quote from: akulion on May 15, 2006, 04:19:30 PMQuote
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Feac.forgiven5.com%2Fpictures%2Fusersonline_helios.png&hash=ac796320fd9b8d971ca498d3507a3e0a3c70b679)
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 codeCode Select
$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 itCode Select
// 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 :)
Quote from: cyberstang5.0 on May 10, 2006, 09:45:24 PMAnyone? ??? ??? :(Quote from: DemonicInfluence on March 08, 2006, 11:37:39 AM
just make it so thatCode Selectif($context['user']['is_admin'])
{
is before the mod stuff in the boardindex.template.php of every theme.
Then at the end putCode Select}
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? ???
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.
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.
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>
Quote from: akulion on May 15, 2006, 01:05:45 PMQuote from: scottws on May 14, 2006, 09:40:50 AMQuote from: akulion on May 11, 2006, 11:47:05 PM"Just place the code..." What code are you referring to? Beemer's code?
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
The code I am referring to is this:Code Select
', $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 :)
Quote from: cotdagoo on June 03, 2006, 03:05:44 PMyou could always ban users from your entire .com via cpanel :)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
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?
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.
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?
$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;
$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;
mysql_free_result($result);
krsort($context['users_online_today']);
krsort($context['list_users_online_today']);
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.
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.
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.
Quote from: edsloter on June 21, 2006, 01:45:58 PMQuote 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
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.
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?
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
Quote from: SurfExcelerator.com on June 28, 2006, 10:13:33 AMYes, i know it but i want to view last ten minute and 24 hour online list
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.
Quote from: DemonicInfluence on June 26, 2006, 07:02:19 PM
only edit boardindex.template.php
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
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
<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>
<td class="windowbg2" style="padding-top:12px; padding-bottom:12px;">
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';
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt[158], ' ', $txt['uot_users_online_today_title'], '" border="0" />
<img src="', $settings['images_url'], '/icons/online.gif" alt="', $txt['uot_users_online_today_title'], '" border="0" />
$txt['uot_users_online_today_title']='Users Logged In Today';
$txt['uot_total_users_online_today']='Users Logged In Today';
$txt['uot_ulit']='Users Logged In Today';
// "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%">';
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
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?
Quote from: Carceri on July 21, 2006, 04:01:18 PMMhh, i can understand that, in some cases nothing other than me *g*
For the time being, I only make the required changes for the default theme, sorry. It's simply due to lack of time.
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.
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 AMQuote 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 findCode Select
$nowdate = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);
And replace withCode Select
$midnight = time() - 86400;
And in Stats.php findCode Select
$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 withCode Select
$midnight = time() - 86400;
Also edit Modifications.english.php to the appropriate text you want displayed
Quote from: Joshsux on August 09, 2006, 01:48:53 AM
but i don't have a stats.php?
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?
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?
Quote from: deadpoeticstar on August 14, 2006, 12:09:08 PM
could this be about ready for an RC3 update?
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.
Quote from: Carceri on May 18, 2006, 07:20:56 AMQuote 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 findCode Select
$nowdate = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $nowdate['mon'], $nowdate['mday'], $nowdate['year']) - ($modSettings['time_offset'] * 3600);
And replace withCode Select
$midnight = time() - 86400;
And in Stats.php findCode Select
$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 withCode Select
$midnight = time() - 86400;
Also edit Modifications.english.php to the appropriate text you want displayed
$date = @getdate(forum_time(false));
$midnight = mktime(0, 0, 0, $date['mon'], $date['mday'], $date['year']) - ($modSettings['time_offset'] * 3600);
// 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);
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?
Quote from: Carceri on August 26, 2006, 05:57:30 AMQuote 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.
Quote from: scottws on August 26, 2006, 04:41:34 PM
So, I'm just changing the midnight part, right?
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 :(
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"?
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?
Quote from: Carceri on September 17, 2006, 06:09:18 AMQuote 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.
Quote from: steve in houston on September 19, 2006, 08:21:07 PM
i havent packaged it up yet but i can.
Quote from: qd-race on September 23, 2006, 10:36:46 AMIt's in "Users_Online_Today_Mod.xml".
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.
<file name="$themedir/BoardIndex.template.php" error="fatal">
Quote from: edi67 on September 24, 2006, 10:48:25 AMIt is not random. It is by the time they last logged in.
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
$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
$context['users_online_today'][$row['memberName']] = array(
Quote from: akabugeyes on September 24, 2006, 10:57:01 AMQuote from: edi67 on September 24, 2006, 10:48:25 AMIt is not random. It is by the time they last logged in.
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
This is untested, but you can try changing in Sources/BoardIndex.phpCode Select$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
toCode Select$context['users_online_today'][$row['memberName']] = array(
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...
Quote from: rockinaway on November 12, 2006, 08:06:23 AM
Can this shows number of guests and spiders which have visited?
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.
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)
Quote from: Carceri on November 17, 2006, 07:41:50 AM
It looks like it, but I have still not tested it :)
Quote from: sager on December 07, 2006, 01:37:34 PM
waiting for 1.1 compatible
$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 ';
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 ?
Quote from: danskmacabre on November 08, 2006, 03:20:44 PM
was very easy to manually add to the helios theme.
Works perfectly.
Quote from: Carceri on December 11, 2006, 01:31:54 AMQuote 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
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.phpCode Select$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
toCode Select$context['users_online_today'][$row['memberName']] = array(
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 ;)
Quote from: Carceri on December 14, 2006, 07:06:02 AMQuote 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.
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.
$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 ';
Quote from: Vinspire on December 23, 2006, 02:50:29 AM
Is it compatible wif SMF 1.1.1 ?
Quote from: Carceri on December 23, 2006, 05:09:31 AMQuote from: Vinspire on December 23, 2006, 02:50:29 AM
Is it compatible wif SMF 1.1.1 ?
Yes it is
Quote from: mcalan2001 on December 13, 2006, 02:39:52 PMQuote 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.phpCode Select$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
toCode Select$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
krsort($context['users_online_today']);
krsort($context['list_users_online_today']);
ksort($context['users_online_today']);
ksort($context['list_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']))
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>';
// 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>';
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!
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 ;)
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!
// 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>';
$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 ';
Quote from: Carceri on December 30, 2006, 08:18:29 AMit's not the basic feature! But a mod is available, many of them are using! Looks pretty good!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.
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?
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>';
</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>';
QuoteThis should be the only edit you have to do. In your BoardIndex.template.php find:
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
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:Code Select</span>
</td>
</tr>';
Before that add:Code Select// 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>';
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';
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?
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:Code Select</span>
</td>
</tr>';
Before that add:Code Select// 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>';
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.
echo $newmembul123 , ' New This Month: ' , $row['month'] , ' ' , $newmembul123 , ' New This Week: ' , $row['week'] , ' ' , $newmembul123 , ' New Today: ' , $row['today'];
// 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>';
<td nowrap="nowrap">', $txt['users_online_today'], ':</td>
<td align="right">', $context['online_today'], '</td>';
<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>';
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
$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';
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 ? ::)
', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</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>';
Quote from: veldfire on March 01, 2007, 04:21:24 PM????
Is there a way to hide the list from guests ?
// "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>
<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>';
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
<td class="catbg" colspan="2">', $txt['uot_users_online_today'], '</td>
$txt['uot_guests']='Guests';
$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''];
}
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'], ')';
$midnight = mktime(0, 0, 0, $date['mon'], $date['mday'], $date['year']) - ($modSettings['time_offset'] * 3600);
uot_yesterday
part used? It doesn't display anywhere and would be handy :)
Quote from: symon on March 12, 2007, 07:00:38 PMhow to show names of users online to guests? it shown number of user online only
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:Code Select// "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:Code Select
<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:Code Select<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
To:Code Select<td class="catbg" colspan="2">', $txt['uot_users_online_today'], '</td>
Does this look ok to you experienced coders? It works great now :)
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
Quote from: symon on March 24, 2007, 11:48:02 AMi'm using another theme...not the babylon themeQuote 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)
Quote from: symon on March 24, 2007, 07:21:50 PMi'm not good at php, can u help me?
That code tweak was for it to work in the babylon theme :(
Quote from: alo on March 26, 2007, 08:04:30 PM
i'm not good at php, can u help me?
Quote from: alo on March 26, 2007, 08:04:30 PMi need that work on another theme but thank you!Quote from: symon on March 24, 2007, 07:21:50 PMi'm not good at php, can u help me?
That code tweak was for it to work in the babylon theme :(
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. :)
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
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
// Set the latest member.
$context['latest_member'] = &$context['common_stats']['latest_member'];
$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);
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'], ')';
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']), ')';
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)
Users Online Today
Total: 10 (Members: 3, Hidden: 0, Guests: 7)
User, User2, User3
Users Logged In Today
Total: 3 (Members: 3, Hidden: 0)
User, User2, User3
Users Logged In Today
Total: 2
QuoteTotal: 14 (Members: 96, Hidden: 0 , Guests: -82)
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!
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 :(
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
QuoteThe package you are trying to download or install is either corrupt or not compatible with this version of SMF.
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?
Quote from: tick on April 21, 2007, 08:46:44 AMQuote 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
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
</span>
</td>
</tr>';
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'], ' • ', $txt[95], ': ', $context['common_stats']['total_posts'], ' • ', $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], ' "', $context['latest_post']['link'], '" ', $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] . ': "' . $context['latest_post']['link'] . '" (' . $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>';
}
?>
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
Quote from: braveboy on April 27, 2007, 03:16:20 AM
any idea how to install it on "Scribbles" theme please help me thanks
Quote from: uni on April 30, 2007, 05:30:30 AMQuote 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';
<file name="$sourcedir/BoardIndex.php">
<file name="$sourcedir/Stats.php">
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?Code Select<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 thisCode Select<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.
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 :)
Quote from: Photoshocker on June 26, 2007, 05:25:01 AMQuote 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?
Quote from: Tick on April 21, 2007, 08:46:44 AMQuote 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
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".
<![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';]]>
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
Quote from: Stargater59 on July 17, 2007, 12:32:35 PM
Is this mod going to be updated for 1.1.3?
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
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'], ' • ', $txt[95], ': ', $context['common_stats']['total_posts'], ' • ', $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], ' "', $context['latest_post']['link'], '" ', $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] . ': "' . $context['latest_post']['link'] . '" (' . $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>';
}
Quote from: Webrunner on December 27, 2006, 05:31:55 PMQuote from: mcalan2001 on December 13, 2006, 02:39:52 PMQuote 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.phpCode Select$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
toCode Select$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:Code Select
krsort($context['users_online_today']);
krsort($context['list_users_online_today']);
change into:Code Select
ksort($context['users_online_today']);
ksort($context['list_users_online_today']);
and the reverse sorting is over ;)
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>';
}
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.
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 ?>Code Select<![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?
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!
uksort($myArray, "strnatcasecmp");
instead of ksort instruction.
Quote from: hugodiaz on August 30, 2007, 03:48:53 PM
Does this mod work for SMF1.1.3?
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! :)
Quote from: Paracelsus on August 05, 2007, 03:29:21 PM
(...) changing in Sources/BoardIndex.phpCode Select$context['users_online_today'][$row['lastLogin'] . $row['memberName']] = array(
toCode Select$context['users_online_today'][$row['memberName']] = array(
(...) that needs to be much the same edit, but about ten lines down.
krsort($context['users_online_today']);
krsort($context['list_users_online_today']);
uksort($myArray, "strnatcasecmp");
Quote from: Pierre29200 on June 01, 2007, 10:07:14 AMThank you, it helped very much :)
Add in mod 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
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
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.
QuoteJesus, why are you being so dramatic? I'm pretty sure that someone will take it, since it's so popular.
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....
Quote from: symon on October 10, 2007, 06:51:58 AMQuoteJesus, 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" cr@p.
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.
QuoteMy comments where not meant to cause issues
Quote from: The Burglar! on October 11, 2007, 09:20:05 AMThanks, please let me know what you discover. :)
@hugodiaz
i'll look into it when i have a little spare time over....
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?
Quote from: snork13 on November 06, 2005, 05:54:53 PM
works great in 1.1rc1, thanks for sharing
-snork
Quote from: pibe86 on October 16, 2007, 11:12:45 PMQuote 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
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.
Quote from: hugodiaz on October 10, 2007, 04:35:52 PMOk, since I haven't really heard anything about this as yet:
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
Quote from: Bigguy on October 17, 2007, 01:20:39 AM
@ Alundra: Do you mean about keeping a log file of logged on users. ???
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
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.
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>';
// 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>';
<?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';
?>
// --- 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';
// --- 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';
Quote from: Eleven0 on November 03, 2007, 10:29:43 PMYes, 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.
How can I change 24 hours to something else?
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
', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</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>';
Quote from: The Burglar! on November 07, 2007, 04:53:20 PM
BoardIndex.template.php search for thisCode Select
', $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 codeCode Select
// 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
Quote from: The Burglar! on November 07, 2007, 04:53:20 PM
BoardIndex.template.php search for thisCode Select
', $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 codeCode Select
// 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
$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';
$txt['users_online_today'] = 'Online Today';
$txt['num_hits'] = 'Total page views';
$txt['average_hits'] = 'Average page views per day';
<?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';
?>
<?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 »';
$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'];
?>
// 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>';
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
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.Code Select
// 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?
Quote from: tick on April 21, 2007, 08:46:44 AMQuote 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
Quote from: The Burglar! on November 07, 2007, 04:53:20 PM
BoardIndex.template.php search for thisCode Select
', $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 codeCode Select
// 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
Quote from: Carceri on October 24, 2007, 05:32:20 AMQuote 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.
Quote from: The Burglar! on November 07, 2007, 04:53:20 PM
BoardIndex.template.php search for thisCode Select
', $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 codeCode Select
// 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
<td class="windowbg" width="20" valign="middle" align="center">
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
FindCode Select// 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 withCode Select// 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>';
//}
Quote from: seek2501 on March 18, 2008, 06:37:27 PM
Shold 1.1.4 users still upgrade?
Quote
Version 1.4.0 is the latest version that supports SMF 1.1.x
Quote from: simon36 on March 18, 2008, 07:40:08 PM
How can I change the reporting period from logged in today to logged in the last 24 hours?
Also how do I change the text from 'Users Logged in Today'?
Quote from: JoshieDaMan on March 19, 2008, 09:21:03 PM
It isn't saying any thing at bottom?
Quote from: JoshieDaMan on March 19, 2008, 11:16:35 PM
1.1.4 SMF.
Custom theme - Phobos.
It installed no errors, and I did edit custom theme and added as said on SMF Package Parser. I edit boardindex, and added modification on there too, still not showing. Is it a option somewhere in admin section or something?
I tried Users_Online_Today_1.5.0.zip it isn't compible with 1.1.4 version as it stated in install package.
So I use 1.4.0.
I am sticking with 1.1.4 forever.
Quote from: Carceri on March 21, 2008, 02:53:09 PMMakes sense. :)
since the final of SMF 2.0 is probably years away, I might create a version 1.4.1 with these changes backported.
Quote from: Carceri on March 21, 2008, 02:53:09 PMIndeed true. And already done :)
Until then, almost all of these new options are also available on version 1.4 of this mod. What you need to chance, is already posted in this thread... somewhere :)
Quote from: seek2501 on March 25, 2008, 08:27:47 PM
Nice update. :)
Shame it's only compatable with the 2.0 beta though - I won't be switching my live site until 2.0 final.
Are there any plans to make 1.5.0 compatible with SMF 1.1.4? It's probably going to be a long time until 2.0 final is out... :(
Quote from: Zygomaticus on March 25, 2008, 08:33:17 PM
Well the older version isn't quite as advanced
Quote from: Zygomaticus on March 25, 2008, 08:39:29 PMA cup of tea and a hot donut would be nice :D
Well what do you want from the new version if the author doesn't upgrade the older version?
Quote from: seek2501 on March 25, 2008, 11:41:46 PM
It's not the timeframe, it's just that the current version (for 1.1.4) doesnt allow guests to view who has visited. For guests it only displays the total number of visitors.
// 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'])
// 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']))
Quote from: seek2501 on March 28, 2008, 02:04:31 AM
Thanks.
Also I noticed an issue with this mod... If a user is banned and tries to access the forum then they still get listed as having logged in.
Banned users should not be listed?
Quote from: seek2501 on March 28, 2008, 02:04:31 AM
Thanks.
Also I noticed an issue with this mod... If a user is banned and tries to access the forum then they still get listed as having logged in.
Banned users should not be listed?
Quote from: Carceri on March 28, 2008, 02:36:35 AMQuote from: seek2501 on March 28, 2008, 02:04:31 AM
Thanks.
Also I noticed an issue with this mod... If a user is banned and tries to access the forum then they still get listed as having logged in.
Banned users should not be listed?
I have not yet tested this myself, but the mod pulls the data from the user database, and if the user is listed as having logged in there, the mod lists him as so. If this is the case, and there is not some other bug, I will not change this, as I want this mod to be consistent with the "last login" time shown in the users profile.
// 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();
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'];
Quote
The file you tried to save generated the following error:
Parse error: syntax error, unexpected $end in BoardIndex.template.php on line 531
Quote from: 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.
Quote from: FragaCampos on April 03, 2008, 02:44:44 PMQuote from: 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.
Hello there.
Tried to install the mod and got the same error. Any suggestion? Thanks.
Quote from: gxpgreg on April 05, 2008, 08:45:23 PM
Hi, just installed users online today. Using SMF 1.1.4 and the default theme. Installed fine except I am missing the header bar that normally says "Users Logged In Today". I am also missing the words Total, Visible and Hidden. Anybody have any ideas? Thanks.
Quote from: SpyDie on April 08, 2008, 05:40:05 AM
gxpgreg,
Post the contents of the default's theme Modifications.english.php file. It can be found in /Themes/default/languages/Modifications.english.php.
QuoteThe package you are trying to download or install is either corrupt or not compatible with this version of SMF.
Quote from: metallica48423 on April 09, 2008, 04:40:50 PM
Are you using the right version? the 1.4 version is for SMF 1.1.4, the other is for 2.0
Quote from: razorblitz07 on April 10, 2008, 02:03:55 AM
everytime I go to my forum as a guest, I can only see the Member count in the panel. How can I make it so that it shows the Members' names that were online on that day?
Quote from: metallica48423 on April 09, 2008, 06:35:44 PM
i don't use the mod, so i don't know if theres major differences. But the 1.4 is the one for SMF 1.1.4
Quote from: FragaCampos on April 16, 2008, 10:44:50 AM
Is there any chance to make it visible only to admins or other specific groups?
8: Undefined index: uot_yesterday
File: /home/jade/public_html/forums/Sources/Subs-MembersOnlineToday.php
Line: 137
$yesterday = $userday == $loginday ? '' : $txt['uot_yesterday'];
Quote from: Kirsty on May 20, 2008, 08:09:02 AMI had the same problem. Try Users_Online_Today_1.4.0.zip. This works for me.
I have downloaded this mod and tried to install today but when I do try I get this...
The package you are trying to download or install is either corrupt or not compatible with this version of SMF.
Yet it clearly says that it's okay for 1.1.5.
Can someone help please?
// "Users online" - in order of activity.
echo '
<tr>
<td class="titlebg" colspan="2">Currently Active Users: ', $context['show_who'] ? '<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'];
// 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 ')';
}
echo $context['show_who'] ? '</a>' : '', '</td>
</tr>
<tr>
<td class="windowbg2">', $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="windowbg" width="100%">
<div class="smalltext">
<div style="white-space: nowrap">', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')</div>
<div>';
// 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['viewing_allowed'])
{
echo '<br />', implode(', ', $context['list_users_online_today']);
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '<br />[' . implode('] [', $context['membergroups']) . ']';
}
echo '</div>';
echo '</td>';
echo '</tr>';
// Show YaBB SP1 style information...
if ($settings['show_sp1_info'])
{
echo '
<tr>
<td class="titlebg" colspan="2">', $txt[645], '</td>
</tr>
<tr>
<td class="windowbg2"><a href="', $scripturl, '?action=stats"><img src="', $settings['images_url'], '/icons/info.gif" alt="', $txt[645], '" border="0" /></a></td>
<td class="windowbg" width="100%">
<div class="smalltext">
<div>', $txt[64], ': ', $context['common_stats']['total_topics'], ', ', $txt[21], ': ', $context['common_stats']['total_posts'], ', ', $txt[19], ': ', $context['common_stats']['total_members'], '
</div>
<div>', $txt[656], ': <b> ', $context['common_stats']['latest_member']['link'], '</b></div>
</div>
</td>
</tr>';
}
echo '
</table>';
<?php
// Version: 1.1; BoardIndex
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="0" 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'], ' &#8226; ', $txt[95], ': ', $context['common_stats']['total_posts'], ' &#8226; ', $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 '
<table border="0" width="100%" class="tborder" cellspacing="' , ($context['browser']['is_ie'] || $context['browser']['is_opera6']) ? '1' : '0' , '" cellpadding="4" style="margin-bottom: 2ex;">
<tr>
<td valign="middle" align="center" height="60" class="windowbg2">';
// 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>';
}
/* 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.) */
$first = true;
foreach ($context['categories'] as $category)
{
echo '
<div class="tborder" style="margin-top: ' , $first ? '0;' : '1ex;' , '' , $context['browser']['needs_size_fix'] && !$context['browser']['is_ie6'] ? 'width: 100%;' : '', '">
<div class="catbg', $category['new'] ? '2' : '', '" style="padding: 5px 5px 5px 10px;">';
$first = false;
// If this category even can collapse, show a link to collapse it.
if ($category['can_collapse'])
echo '
<span style="float:right; margin-right:15px;"><a href="', $category['collapse_href'], '"><img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/', !$category['is_collapsed'] ? 'collapse.gif' : 'expand.gif', '" alt="*" /></a></span>';
echo '
<span style="margin-left:80px;">', $category['link'], '</span>
</div>';
// Assuming the category hasn't been collapsed...
if (!$category['is_collapsed'])
{
echo '
<table border="0" width="100%" cellspacing="1" cellpadding="5" class="bordercolor" style="margin-top: 0px;">
',
empty($settings['boardname_posts_lastposts_nodisplay']) ? '<tr>
<td class="titlebg3" width="51" align="center" valign="middle">
</td>
<td class="titlebg3">
'. $txt[20].'
</td>
<td class="titlebg3" valign="middle" align="center" style="width: 12ex;">
'. $txt[21].'
</td>
<td class="titlebg3" valign="middle" align="center" width="22%">
'. $txt[22].'
</td>
</tr>' : '' ;
/* 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="51" align="center" valign="middle"><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'] . '/'. $settings['theme_main_color'], '/on.gif" alt="', $txt[333], '" title="', $txt[333], '" />';
// This board doesn't have new posts, but its children do.
elseif ($board['children_new'])
echo '<img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/on2.gif" alt="', $txt[333], '" title="', $txt[333], '" />';
// No new posts at all! The agony!!
else
echo '<img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/off.gif" alt="', $txt[334], '" title="', $txt[334], '" />';
echo '</a>
</td>
<td class="windowbg2" style="padding-top:12px; padding-bottom:12px;">
<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"><br/><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'] ? '<img style="margin-right:5px;" src="' . $settings['images_url'] . '/' . $settings['theme_main_color'] . '/onk.gif" alt="' . $txt[333] . '"/><b>' . $child['link'] . '</b>' : '<img style="margin-right:5px;" src="' . $settings['images_url'] . '/' . $settings['theme_main_color'] . '/offk.gif" alt="' . $txt[334] . '"/>' . $child['link'];
}
echo '
<table style="float:right; margin-top: 15px;" width="100%" cellspacing="0" cellpadding="3" border="0">
<tr>
<td class="middletext" valign="middle" align="center" width="30%">
<b>', $txt['parent_boards'], ':</b>
';
$child_counter = 0;
if(empty($settings['child_boards_rows']))
{
echo '
</td>
<td class="middletext" valign="top">';
for(; $child_counter < ceil(count($children)/2); $child_counter++)
echo $children[$child_counter], '<br/>';
}
echo '
</td>
<td class="middletext" valign="top">';
for(; $child_counter < count($children); $child_counter++)
echo $children[$child_counter], '<br/>';
echo '
</td>
</tr>
</table>';
}
// 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], ' <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 '
<b>', $txt[22], '</b> ', $txt[525], ' ', $board['last_post']['member']['link'] , '<br />
', $txt['smf88'], ' ', $board['last_post']['link'], '<br />
', $txt[30], ' ', $board['last_post']['time'];
echo '
</span>
</td>
</tr>';
}
echo '
</table>';
}
echo '
</div>';
}
if ($context['user']['is_logged'])
{
echo '
<table border="0" width="100%" cellspacing="0" cellpadding="5">
<tr>
<td align="', !$context['right_to_left'] ? 'left' : 'right', '" class="smalltext">
<img src="' . $settings['images_url'] . '/'. $settings['theme_main_color'] . '/new_some.gif" alt="" align="middle" /> ', $txt[333], '
<img src="' . $settings['images_url'] . '/'. $settings['theme_main_color'] . '/new_none.gif" alt="" align="middle" style="margin-left: 4ex;" /> ', $txt[334], '
</td>
<td align="', !$context['right_to_left'] ? 'right' : 'left', '">';
// Mark read button.
$mark_read_button = array('markread' => array('text' => 452, 'image' => 'markread.gif', 'lang' => true, 'url' => $scripturl . '?action=markasread;sa=all;sesc=' . $context['session_id']));
// Show the mark all as read button?
if ($settings['show_mark_read'] && !empty($context['categories']))
echo '
<table cellpadding="0" cellspacing="0" border="0" style="position: relative; top: 0px;">
<tr>
', template_button_strip($mark_read_button, 'top'), '
</tr>
</table>';
echo '
</td>
</tr>
</table>';
}
// Here's where the "Info Center" starts...
echo '<br />
<div class="tborder" ', $context['browser']['needs_size_fix'] && !$context['browser']['is_ie6'] ? 'style="width: 100%;"' : '', '>
<div class="catbg" style="padding: 6px; vertical-align: middle; text-align: center; ">
<a href="#" onclick="shrinkHeaderIC(!current_header_ic); return false;"><img id="upshrink_ic" src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/', empty($options['collapse_header_ic']) ? 'collapse.gif' : 'expand.gif', '" alt="*" title="', $txt['upshrink_description'], '" style="margin-right: 2ex;" align="right" /></a>
', $txt[685], '
</div>
<div id="upshrinkHeaderIC"', empty($options['collapse_header_ic']) ? '' : ' style="display: none;"', '>
<table border="0" width="100%" cellspacing="1" cellpadding="4" class="bordercolor">';
// This is the "Recent Posts" bar.
if (!empty($settings['number_recent_posts']))
{
echo '
<tr>
<td class="titlebg" 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], '" /></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], ' "', $context['latest_post']['link'], '" ', $txt[235], ' (', $context['latest_post']['time'], ')<br />
</div>';
}
// Show lots of posts.
elseif (!empty($context['latest_posts']))
{
echo '
<table cellpadding="0" cellspacing="0" width="100%">';
/* 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="windowbg" valign="middle" width="40%" style="padding-left: 10px; font-size:85%">', $post['link'], '</td>
<td class="windowbg" valign="middle" width="15%" style="padding-left: 10px; font-size:85%" nowrap="nowrap">', $post['poster']['link'], '</td>
<td class="windowbg" valign="middle" width="25%" style="padding-left: 10px; font-size:85%" nowrap="nowrap">', $post['board']['link'], '</td>
<td class="windowbg" valign="middle" width="20%" style="padding-left: 10px; font-size:85%" 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="titlebg" 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'], '" /></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>';
}
// Show YaBB SP1 style information...
if ($settings['show_sp1_info'])
{
echo '
<tr>
<td class="titlebg" 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], '" /></a>
</td>
<td class="windowbg2" width="100%">
<span class="middletext">
', $context['common_stats']['total_posts'], ' ', $txt[95], ' ', $txt['smf88'], ' ', $context['common_stats']['total_topics'], ' ', $txt[64], ' ', $txt[525], ' ', $context['common_stats']['total_members'], ' ', $txt[19], '. ', $txt[656], ': <b> ', $context['common_stats']['latest_member']['link'], '</b>
<br /> ' . $txt[659] . ': <b>"' . $context['latest_post']['link'] . '"</b> ( ' . $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>' : '', '
</span>
</td>
</tr>';
}
// "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%">';
echo '
', $context['show_who'] ? '<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'];
// 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 ')';
}
echo $context['show_who'] ? '</a>' : '', '
<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>
<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>';
// 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="titlebg" 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], '" />', $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="titlebg" 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], '" /></a>
</td>
<td class="windowbg2" valign="middle">
<form action="', $scripturl, '?action=login2" method="post" accept-charset="', $context['character_set'], '" 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>
</div>';
}
?>
<?php
// Version: 1.1; BoardIndex
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="0" 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'], ' &#8226; ', $txt[95], ': ', $context['common_stats']['total_posts'], ' &#8226; ', $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 '
<table border="0" width="100%" class="tborder" cellspacing="' , ($context['browser']['is_ie'] || $context['browser']['is_opera6']) ? '1' : '0' , '" cellpadding="4" style="margin-bottom: 2ex;">
<tr>
<td valign="middle" align="center" height="60" class="windowbg2">';
// 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>';
}
/* 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.) */
$first = true;
foreach ($context['categories'] as $category)
{
echo '
<div class="tborder" style="margin-top: ' , $first ? '0;' : '1ex;' , '' , $context['browser']['needs_size_fix'] && !$context['browser']['is_ie6'] ? 'width: 100%;' : '', '">
<div class="catbg', $category['new'] ? '2' : '', '" style="padding: 5px 5px 5px 10px;">';
$first = false;
// If this category even can collapse, show a link to collapse it.
if ($category['can_collapse'])
echo '
<span style="float:right; margin-right:15px;"><a href="', $category['collapse_href'], '"><img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/', !$category['is_collapsed'] ? 'collapse.gif' : 'expand.gif', '" alt="*" /></a></span>';
echo '
<span style="margin-left:80px;">', $category['link'], '</span>
</div>';
// Assuming the category hasn't been collapsed...
if (!$category['is_collapsed'])
{
echo '
<table border="0" width="100%" cellspacing="1" cellpadding="5" class="bordercolor" style="margin-top: 0px;">
',
empty($settings['boardname_posts_lastposts_nodisplay']) ? '<tr>
<td class="titlebg3" width="51" align="center" valign="middle">
</td>
<td class="titlebg3">
'. $txt[20].'
</td>
<td class="titlebg3" valign="middle" align="center" style="width: 12ex;">
'. $txt[21].'
</td>
<td class="titlebg3" valign="middle" align="center" width="22%">
'. $txt[22].'
</td>
</tr>' : '' ;
/* 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="51" align="center" valign="middle"><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'] . '/'. $settings['theme_main_color'], '/on.gif" alt="', $txt[333], '" title="', $txt[333], '" />';
// This board doesn't have new posts, but its children do.
elseif ($board['children_new'])
echo '<img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/on2.gif" alt="', $txt[333], '" title="', $txt[333], '" />';
// No new posts at all! The agony!!
else
echo '<img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/off.gif" alt="', $txt[334], '" title="', $txt[334], '" />';
echo '</a>
</td>
<td class="windowbg2" style="padding-top:12px; padding-bottom:12px;">
<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"><br/><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'] ? '<img style="margin-right:5px;" src="' . $settings['images_url'] . '/' . $settings['theme_main_color'] . '/onk.gif" alt="' . $txt[333] . '"/><b>' . $child['link'] . '</b>' : '<img style="margin-right:5px;" src="' . $settings['images_url'] . '/' . $settings['theme_main_color'] . '/offk.gif" alt="' . $txt[334] . '"/>' . $child['link'];
}
echo '
<table style="float:right; margin-top: 15px;" width="100%" cellspacing="0" cellpadding="3" border="0">
<tr>
<td class="middletext" valign="middle" align="center" width="30%">
<b>', $txt['parent_boards'], ':</b>
';
$child_counter = 0;
if(empty($settings['child_boards_rows']))
{
echo '
</td>
<td class="middletext" valign="top">';
for(; $child_counter < ceil(count($children)/2); $child_counter++)
echo $children[$child_counter], '<br/>';
}
echo '
</td>
<td class="middletext" valign="top">';
for(; $child_counter < count($children); $child_counter++)
echo $children[$child_counter], '<br/>';
echo '
</td>
</tr>
</table>';
}
// 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], ' <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 '
<b>', $txt[22], '</b> ', $txt[525], ' ', $board['last_post']['member']['link'] , '<br />
', $txt['smf88'], ' ', $board['last_post']['link'], '<br />
', $txt[30], ' ', $board['last_post']['time'];
echo '
</span>
</td>
</tr>';
}
echo '
</table>';
}
echo '
</div>';
}
if ($context['user']['is_logged'])
{
echo '
<table border="0" width="100%" cellspacing="0" cellpadding="5">
<tr>
<td align="', !$context['right_to_left'] ? 'left' : 'right', '" class="smalltext">
<img src="' . $settings['images_url'] . '/'. $settings['theme_main_color'] . '/new_some.gif" alt="" align="middle" /> ', $txt[333], '
<img src="' . $settings['images_url'] . '/'. $settings['theme_main_color'] . '/new_none.gif" alt="" align="middle" style="margin-left: 4ex;" /> ', $txt[334], '
</td>
<td align="', !$context['right_to_left'] ? 'right' : 'left', '">';
// Mark read button.
$mark_read_button = array('markread' => array('text' => 452, 'image' => 'markread.gif', 'lang' => true, 'url' => $scripturl . '?action=markasread;sa=all;sesc=' . $context['session_id']));
// Show the mark all as read button?
if ($settings['show_mark_read'] && !empty($context['categories']))
echo '
<table cellpadding="0" cellspacing="0" border="0" style="position: relative; top: 0px;">
<tr>
', template_button_strip($mark_read_button, 'top'), '
</tr>
</table>';
echo '
</td>
</tr>
</table>';
}
// Here's where the "Info Center" starts...
echo '<br />
<div class="tborder" ', $context['browser']['needs_size_fix'] && !$context['browser']['is_ie6'] ? 'style="width: 100%;"' : '', '>
<div class="catbg" style="padding: 6px; vertical-align: middle; text-align: center; ">
<a href="#" onclick="shrinkHeaderIC(!current_header_ic); return false;"><img id="upshrink_ic" src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/', empty($options['collapse_header_ic']) ? 'collapse.gif' : 'expand.gif', '" alt="*" title="', $txt['upshrink_description'], '" style="margin-right: 2ex;" align="right" /></a>
', $txt[685], '
</div>
<div id="upshrinkHeaderIC"', empty($options['collapse_header_ic']) ? '' : ' style="display: none;"', '>
<table border="0" width="100%" cellspacing="1" cellpadding="4" class="bordercolor">';
// This is the "Recent Posts" bar.
if (!empty($settings['number_recent_posts']))
{
echo '
<tr>
<td class="titlebg" 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], '" /></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], ' "', $context['latest_post']['link'], '" ', $txt[235], ' (', $context['latest_post']['time'], ')<br />
</div>';
}
// Show lots of posts.
elseif (!empty($context['latest_posts']))
{
echo '
<table cellpadding="0" cellspacing="0" width="100%">';
/* 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="windowbg" valign="middle" width="40%" style="padding-left: 10px; font-size:85%">', $post['link'], '</td>
<td class="windowbg" valign="middle" width="15%" style="padding-left: 10px; font-size:85%" nowrap="nowrap">', $post['poster']['link'], '</td>
<td class="windowbg" valign="middle" width="25%" style="padding-left: 10px; font-size:85%" nowrap="nowrap">', $post['board']['link'], '</td>
<td class="windowbg" valign="middle" width="20%" style="padding-left: 10px; font-size:85%" 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="titlebg" 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'], '" /></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>';
}
// Show YaBB SP1 style information...
if ($settings['show_sp1_info'])
{
echo '
<tr>
<td class="titlebg" 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], '" /></a>
</td>
<td class="windowbg2" width="100%">
<span class="middletext">
', $context['common_stats']['total_posts'], ' ', $txt[95], ' ', $txt['smf88'], ' ', $context['common_stats']['total_topics'], ' ', $txt[64], ' ', $txt[525], ' ', $context['common_stats']['total_members'], ' ', $txt[19], '. ', $txt[656], ': <b> ', $context['common_stats']['latest_member']['link'], '</b>
<br /> ' . $txt[659] . ': <b>"' . $context['latest_post']['link'] . '"</b> ( ' . $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>' : '', '
</span>
</td>
</tr>';
}
// "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%">';
echo '
', $context['show_who'] ? '<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'];
// 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 ')';
}
echo $context['show_who'] ? '</a>' : '', '
<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>
<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>';
// 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>';
// 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="titlebg" 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], '" />', $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="titlebg" 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], '" /></a>
</td>
<td class="windowbg2" valign="middle">
<form action="', $scripturl, '?action=login2" method="post" accept-charset="', $context['character_set'], '" 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>
</div>';
}
?>
http://www.org/forums/index.php?wwwRedirect
8: Undefined index: uot_yesterday
File: /home/*******/public_html/forums/Sources/Subs-MembersOnlineToday.php
Line: 135
// Users online today
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>';
==>135:$yesterday = $userday == $loginday ? '' : $txt['uot_yesterday'];
QuoteYou can customise a few options. See the included readme.txt file for details.
<?php
// Version: 1.1.3; BoardIndex
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'], ' &#8226; ', $txt[95], ': ', $context['common_stats']['total_posts'], ' &#8226; ', $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="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"><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>
<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="small2text windowbg2" valign="middle" width="4%" align="center">
', $board['posts'], '</td><td class="smalltext" valign="middle" width="4%" align="center">
', $board['topics'],'</td><td class="smalltext" valign="middle" width="22%">';
if (!empty($board['last_post']['id']))
echo '
<a href="', $board['last_post']['href'], '"><img alt="go" src="', $settings['images_url'], '/icons/last_post.gif" align="right" hspace="3" border="0" /></a>
', $board['last_post']['time'], '
', $txt['smf88'], ' <b>', $board['last_post']['link'], '</b> ', $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="catbg">
<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'] && !empty($context['categories']))
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>
<td class="blocktitle" align="center" colspan="2"><b>', $txt[685], '</b></td>
</tr>';
// This is the "Recent Posts" bar.
if (!empty($settings['number_recent_posts']))
{
echo '
<tr>
<td class="titlebg" 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], ' "', $context['latest_post']['link'], '" ', $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="titlebg" 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="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>';
}
// Show a member bar. Not heavily ornate, but functional at least.
if ($settings['show_member_bar'])
{
echo '
<tr>
<td class="titlebg" 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="titlebg" 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] . ': "' . $context['latest_post']['link'] . '" (' . $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="titlebg" 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="titlebg" 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="titlebg" 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" accept-charset="', $context['character_set'], '" 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>';
}
?>
<file name="$themedir/BoardIndex.template.php">
<operation>
<search position="before"><![CDATA[ ', $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'], '</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>';]]>
</add>
</operation>
</file>
', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
in my template file...Quote from: SgtMic on June 11, 2008, 06:38:30 PM
Error log is filling up with this one:Code Selecthttp://www.org/forums/index.php?wwwRedirect
8: Undefined index: uot_yesterday
File: /home/*******/public_html/forums/Sources/Subs-MembersOnlineToday.php
Line: 135
SMF 2.0 Beta 3.1 Public
Mods:
1. More Spiders 1.1
2. Are You Human? Anti-Bot Registration Check 1.3
3. Add Domaintools to TrackIP 1.1
4. Auto Embed Video/Audio Clips 3.0
5. SMF Sitemap 1.3.0
6. Recount Posts Maintenance 1.1
7. Users Online Today 1.5.2
8. Treasury 2.23
9. Grouped Who's Online 1.0
10. Top 10 Posters Today And This Week Stats
Quote from: DirtRider on June 22, 2008, 04:19:00 AM
SMF 1.1.5
Users Online Today Mod 1.5.2
Forum Link - http://www.s247631067.onlinehome.us/index.php (http://www.s247631067.onlinehome.us/index.php)
When trying to install this mod I get the following error, any ideas on this?
The package you are trying to download or install is either corrupt or not compatible with this version of SMF.
Quote from: tones_ie on June 22, 2008, 05:23:51 PM
for 1.1.5 smf..u need Users_Online_Today_1.4.0.zip
Quote from: seek2501 on June 22, 2008, 05:32:44 PMQuote from: tones_ie on June 22, 2008, 05:23:51 PM
for 1.1.5 smf..u need Users_Online_Today_1.4.0.zip
Yes, we know that... But 1.4.0 has less features. People are requesting a version of 1.5.2 which is compatible with SMF 1.1.5
<?php
$txt['uot_users_online_today']='Membros registrado hoje';
$txt['uot_yesterday']='Ontem em ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visível';
$txt['uot_hidden']='Escondido';
?>
<?php
$txt['uot_users_online_today']='Membros registrado hoje';
$txt['uot_yesterday']='Ontem em ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visível';
$txt['uot_hidden']='Escondido';
?>
<file name="$languagedir/Modifications.portuguese.php" error="skip">
<operation>
<search position="end"></search>
<add><![CDATA[$txt['uot_users_online_today']='Membros registrado hoje';
$txt['uot_yesterday']='Ontem em ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visível';
$txt['uot_hidden']='Escondido';]]>
</add>
</operation>
</file>
<file name="$languagedir/Modifications.brazilian.php" error="skip">
<operation>
<search position="end"></search>
<add><![CDATA[$txt['uot_users_online_today']='Membros registrado hoje';
$txt['uot_yesterday']='Ontem em ';
$txt['uot_total']='Total';
$txt['uot_visible']='Visível';
$txt['uot_hidden']='Escondido';]]>
</add>
</operation>
</file>
<file name="$languagedir/Stats.portuguese.php" error="skip">
<operation>
<search position="replace"><![CDATA[$txt['users_online_today'] = 'Hoje On-line';
$txt['num_hits'] = 'Total de pagina vistas';
$txt['average_hits'] = 'Media de visitas por dia';
]]></search>
<add><![CDATA[$txt['users_online_today'] = 'Hoje On-line';
$txt['num_hits'] = 'Total de pagina vistas';
$txt['average_hits'] = 'Media de visitas por dia';]]>
</add>
</operation>
</file>
<file name="$languagedir/Stats.brazilian.php" error="skip">
<operation>
<search position="replace"><![CDATA[$txt['users_online_today'] = 'Hoje On-line';
$txt['num_hits'] = 'Total de pagina vistas';
$txt['average_hits'] = 'Media de visitas por dia';
]]></search>
<add><![CDATA[$txt['users_online_today'] = 'Hoje On-line';
$txt['num_hits'] = 'Total de pagina vistas';
$txt['average_hits'] = 'Media de visitas por dia';]]>
</add>
</operation>
</file>
<?php
// Version: 1.1; index
/* This template is, perhaps, the most important template in the theme. It
contains the main template layer that displays the header and footer of
the forum, namely with main_above and main_below. It also contains the
menu sub template, which appropriately displays the menu; the init sub
template, which is there to set the theme up; (init can be missing.) and
the linktree sub template, which sorts out the link tree.
The init sub template should load any data and set any hardcoded options.
The main_above sub template is what is shown above the main content, and
should contain anything that should be shown up there.
The main_below sub template, conversely, is shown after the main content.
It should probably contain the copyright statement and some other things.
The linktree sub template should display the link tree, using the data
in the $context['linktree'] variable.
The menu sub template should display all the relevant buttons the user
wants and or needs.
For more information on the templating system, please see the site at:
http://www.simplemachines.org/
*/
// Initialize the template... mainly little settings.
function template_init()
{
global $context, $settings, $options, $txt;
/* Use images from default theme when using templates from the default theme?
if this is 'always', images from the default theme will be used.
if this is 'defaults', images from the default theme will only be used with default templates.
if this is 'never' or isn't set at all, images from the default theme will not be used. */
$settings['use_default_images'] = 'never';
/* What document type definition is being used? (for font size and other issues.)
'xhtml' for an XHTML 1.0 document type definition.
'html' for an HTML 4.01 document type definition. */
$settings['doctype'] = 'xhtml';
/* The version this template/theme is for.
This should probably be the version of SMF it was created for. */
$settings['theme_version'] = '1.1';
/* Set a setting that tells the theme that it can render the tabs. */
$settings['use_tabs'] = true;
/* Use plain buttons - as oppossed to text buttons? */
$settings['use_buttons'] = true;
/* Show sticky and lock status seperate from topic icons? */
$settings['seperate_sticky_lock'] = true;
// Color changer
if(!$context['user']['is_guest'] && isset($_POST['options']['theme_color']))
{
include_once($GLOBALS['sourcedir'] . '/Profile.php');
makeThemeChanges($context['user']['id'], $settings['theme_id']);
$options['theme_color'] = $_POST['options']['theme_color'];
}
elseif ($context['user']['is_guest'])
{
if (isset($_POST['options']['theme_color']))
{
$_SESSION['theme_color'] = $_POST['options']['theme_color'];
$options['theme_color'] = $_SESSION['theme_color'];
}
elseif (isset($_SESSION['theme_color']))
$options['theme_color'] = $_SESSION['theme_color'];
}
}
// The main sub template above the content.
function template_main_above()
{
global $context, $settings, $options, $scripturl, $txt, $modSettings;
// Show right to left and the character set for ease of translating.
echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"', $context['right_to_left'] ? ' dir="rtl"' : '', '><head>
<meta http-equiv="Content-Type" content="text/html; charset=', $context['character_set'], '" />
<meta name="description" content="', $context['page_title'], '" />', empty($context['robot_no_index']) ? '' : '
<meta name="robots" content="noindex" />', '
<meta name="keywords" content="PHP, MySQL, bulletin, board, free, open, source, smf, simple, machines, forum" />
<script language="JavaScript" type="text/javascript" src="', $settings['default_theme_url'], '/script.js?fin11"></script>
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var smf_theme_url = "', $settings['theme_url'], '";
var smf_images_url = "', $settings['images_url'], '";
var smf_scripturl = "', $scripturl, '";
var smf_iso_case_folding = ', $context['server']['iso_case_folding'] ? 'true' : 'false', ';
var smf_charset = "', $context['character_set'], '";
// ]]></script>
<title>', $context['page_title'], '</title>';
// Any color set by user?
if (isset($options['theme_color']))
$settings['theme_main_color'] = $options['theme_color'];
// If not set, or if not allowed to set
if(!isset($options['theme_color']) || (isset($settings['allow_color_change']) && $settings['allow_color_change'] == 'no'))
{
// Defaults.
$options['theme_color'] = isset($settings['theme_main_color']) ? $settings['theme_main_color'] : 'lightblue';
$settings['theme_main_color'] = $options['theme_color'];
}
// The ?fin11 part of this link is just here to make sure browsers don't cache it wrongly.
echo '
<link rel="stylesheet" type="text/css" href="', $settings['theme_url'], '/style.css?fin11" />
<link rel="stylesheet" type="text/css" href="', $settings['theme_url'], '/style_' , $settings['theme_main_color'] , '.css?fin11" />
<link rel="stylesheet" type="text/css" href="', $settings['default_theme_url'], '/print.css?fin11" media="print" />';
/* Internet Explorer 4/5 and Opera 6 just don't do font sizes properly. (they are big...)
Thus, in Internet Explorer 4, 5, and Opera 6 this will show fonts one size smaller than usual.
Note that this is affected by whether IE 6 is in standards compliance mode.. if not, it will also be big.
Standards compliance mode happens when you use xhtml... */
if ($context['browser']['needs_size_fix'])
echo '
<link rel="stylesheet" type="text/css" href="', $settings['default_theme_url'], '/fonts-compat.css" />';
// Show all the relative links, such as help, search, contents, and the like.
echo '
<link rel="help" href="', $scripturl, '?action=help" target="_blank" />
<link rel="search" href="' . $scripturl . '?action=search" />
<link rel="contents" href="', $scripturl, '" />';
// If RSS feeds are enabled, advertise the presence of one.
if (!empty($modSettings['xmlnews_enable']))
echo '
<link rel="alternate" type="application/rss+xml" title="', $context['forum_name'], ' - RSS" href="', $scripturl, '?type=rss;action=.xml" />';
// If we're viewing a topic, these should be the previous and next topics, respectively.
if (!empty($context['current_topic']))
echo '
<link rel="prev" href="', $scripturl, '?topic=', $context['current_topic'], '.0;prev_next=prev" />
<link rel="next" href="', $scripturl, '?topic=', $context['current_topic'], '.0;prev_next=next" />';
// If we're in a board, or a topic for that matter, the index will be the board's index.
if (!empty($context['current_board']))
echo '
<link rel="index" href="' . $scripturl . '?board=' . $context['current_board'] . '.0" />';
// We'll have to use the cookie to remember the header...
if ($context['user']['is_guest'])
$options['collapse_header'] = !empty($_COOKIE['upshrink']);
// Output any remaining HTML headers. (from mods, maybe?)
echo $context['html_headers'], '
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var current_leftbar = ', empty($options['collapse_leftbar']) ? 'false' : 'true', ';
function shrinkHeaderLeftbar(mode)
{';
// Guests don't have theme options!!
if ($context['user']['is_guest'])
echo '
document.cookie = "upshrink=" + (mode ? 1 : 0);';
else
echo '
smf_setThemeOption("collapse_leftbar", mode ? 1 : 0, null, "', $context['session_id'], '");';
echo '
document.getElementById("upshrinkLeftbar").src = smf_images_url + (mode ? "/upshrink2.gif" : "/upshrink.gif");
document.getElementById("leftbarHeader").style.display = mode ? "none" : "";
current_leftbar = mode;
}
// ]]></script>
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var current_rightbar = ', empty($options['collapse_rightbar']) ? 'false' : 'true', ';
function shrinkHeaderRightbar(mode)
{';
// Guests don't have theme options!!
if ($context['user']['is_guest'])
echo '
document.cookie = "upshrink=" + (mode ? 1 : 0);';
else
echo '
smf_setThemeOption("collapse_rightbar", mode ? 1 : 0, null, "', $context['session_id'], '");';
echo '
document.getElementById("upshrinkRightbar").src = smf_images_url + (mode ? "/upshrink2.gif" : "/upshrink.gif");
document.getElementById("rightbarHeader").style.display = mode ? "none" : "";
current_rightbar = mode;
}
// ]]></script>
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var current_header = ', empty($options['collapse_header']) ? 'false' : 'true', ';
function shrinkHeader(mode)
{';
// Guests don't have theme options!!
if ($context['user']['is_guest'])
echo '
document.cookie = "upshrink=" + (mode ? 1 : 0);';
else
echo '
smf_setThemeOption("collapse_header", mode ? 1 : 0, null, "', $context['session_id'], '");';
echo '
document.getElementById("upshrink").src = smf_images_url + ' . '"/'. $settings['theme_main_color'] . '" + (mode ? "/expand.gif" : "/collapse.gif");
document.getElementById("upshrinkHeader").style.display = mode ? "none" : "";
document.getElementById("upshrinkHeader2").style.display = mode ? "none" : "";
current_header = mode;
}
// ]]></script>';
// the routine for the info center upshrink
echo '
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var current_header_ic = ', empty($options['collapse_header_ic']) ? 'false' : 'true', ';
function shrinkHeaderIC(mode)
{';
if ($context['user']['is_guest'])
echo '
document.cookie = "upshrinkIC=" + (mode ? 1 : 0);';
else
echo '
smf_setThemeOption("collapse_header_ic", mode ? 1 : 0, null, "', $context['session_id'], '");';
echo '
document.getElementById("upshrink_ic").src = smf_images_url + ' . '"/'. $settings['theme_main_color'] . '" + (mode ? "/expand.gif" : "/collapse.gif");
document.getElementById("upshrinkHeaderIC").style.display = mode ? "none" : "";
current_header_ic = mode;
}
// ]]></script>
</head>
<body>';
// TinyPortal start
if($context['TPortal']['fixed_width']!=0)
echo '<table align="center" width="'.$context['TPortal']['fixed_width'].'" cellpadding="0" cellspacing="0" border="0"><tr><td>';
// TinyPortal end
echo '
<div class="maindiv" style="width: ' , (isset($settings['page_div_width']) && !empty($settings['page_div_width'])) ? $settings['page_div_width'] : '99%' , ';">
<div width="100%" class="topbar" id="upshrinkHeader"', empty($options['collapse_header']) ? '' : ' style="display: none;"', '>
<table cellspacing="0" cellpadding="0" border="0" style="width:100%;">
<tr>
<td style="padding:0;" width="1" height="120">';
/// my code here
if (empty($settings['header_logo_url']))
echo '
<a href="', $scripturl, '"><img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/logo.jpg" style="margin: 0px;" alt="', $context['forum_name'], '" title="', $context['forum_name'], '"/></a>';
else
echo '
<a href="', $scripturl, '"><img src="', $settings['header_logo_url'], '" style="margin: 0px;" alt="', $context['forum_name'], '" /></a>';
/// end my code
echo '
</td>';
if (!empty($settings['show_name_near_logo']))
echo '
<td>
<span style="font-family: \'Trebuchet MS\', Verdana, sans-serif; font-size: 200%; color: white; padding-top: 30px; padding-left: 30px; white-space: normal;"><strong>', $context['forum_name'], '</strong></span>
</td>';
if (!empty($settings['top_right_html']))
echo '
<td valign="top" align="right">
<div style="color: white; padding-top: 10px; float:right;">', $settings['top_right_html'], '</div>
</td>';
echo '
</tr>
</table>
</div>
<div style="width: 100%; padding-top: 4px;" class="topbar2">
<table border="0" cellspacing="0" cellpadding="0" style="width: 100%;">
<tr>';
// Show a random news item? (or you could pick one from news_lines...)
if (!empty($settings['enable_news']))
echo '
<td valign="middle" height="30" class="smalltext" style="padding-left:10px; padding-top:0px; padding-bottom:0px;">
<b>', $txt[102], '</b>: ', $context['random_news_line'], '
</td>
';
echo '
<td valign="middle" height="30" style="padding-top:0px; padding-bottom:0px; padding-right:20px;" class="middletext" align="right">
<form action="', $scripturl, '?action=search2" method="post" accept-charset="', $context['character_set'], '" style="margin: 0px;">
<a href="', $scripturl, '?action=search;advanced"><img src="'.$settings['images_url'].'/filter.gif" align="middle" style="margin: 0px;" alt="" /></a>
<input type="text" name="search" value="" style="width: 190px;" />
<input type="submit" name="submit" value="', $txt[182], '" style="width: 11ex;" />
<input type="hidden" name="advanced" value="0" />';
// Search within current topic?
if (!empty($context['current_topic']))
echo '
<input type="hidden" name="topic" value="', $context['current_topic'], '" />';
// If we're on a certain board, limit it to this board ;).
elseif (!empty($context['current_board']))
echo '
<input type="hidden" name="brd[', $context['current_board'], ']" value="', $context['current_board'], '" />';
echo '
</form>
</td>
</tr>
</table>
</div>
<div class="menubar">
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tr>';
// Show the menu here, according to the menu sub template.
template_menu();
echo '
</tr>
</table>
</div>';
// Here we start the main page, after the menu bar.
// Unfortunately, IE 6 couldn't handle a div here with a CSS background property, no matter how much I tried. So we use a table for IE here. I love Firefox ^_^ visit getfirefox.com for more info.
// It is time for Microsoft to get rid of IE and make Firefox their primary browser :P
// Ok, Opera can also display the div properly. I love both FF & Opera :)
echo '
', $context['browser']['is_ie'] ? '<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tr><td class="mainpage">' : '<div class="mainpage">', '
<a style="float:right;" href="#" onclick="shrinkHeader(!current_header); return false;"><img id="upshrink" src="', $settings['images_url'], '/', $settings['theme_main_color'], '/', empty($options['collapse_header']) ? 'collapse.gif' : 'expand.gif', '" alt="*" title="', $txt['upshrink_description'], '" align="bottom" style="margin: 0 1ex;" /></a><br />';
//TinyPortal Hide user info/news start
if($context['TPortal']['showtop']==1)
{
echo '<div class="memberbardiv">
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr>
<td width="20">
</td>
<td class="memberbar">';
if($context['user']['is_logged'])
echo '
', $txt['hello_member_ndt'], ' <b>', $context['user']['name'] , '</b>';
else
echo $txt['welcome_guest'];
echo '
</td>
<td class="middletext" align="right" valign="top" style="padding-right:10px; padding-left:10px;">
' , $context['current_time'], '
<br/>
</td>
</tr>
<tr>
<td valign="middle" width="1" style="padding-right:10px; padding-left:10px;">', !empty($context['user']['avatar']) ? $context['user']['avatar']['image'] : '', '</td>
<td class="memberbar">';
if($context['user']['is_logged'])
echo '
<br/>
<span class="middletext">'
, $context['allow_pm'] ? '<b>' . $txt[152] . ' <a href="' . $scripturl . '?action=pm">' . $context['user']['messages'] . ' ' . ($context['user']['messages'] != 1 ? $txt[153] : $txt[471]) . '</a>' . $txt['newmessages4'] . ' ' . $context['user']['unread_messages'] . ' ' . ($context['user']['unread_messages'] == 1 ? $txt['newmessages0'] : $txt['newmessages1']).'</b>' : '<br/>', '.<br/><br/>
> <a href="', $scripturl, '?action=unread">', $txt['unread_since_visit'], '</a> <br />
> <a href="', $scripturl, '?action=unreadreplies">', $txt['show_unread_replies'], '</a><br />
</span>';
echo '
</td>
<td class="middletext" align="right" valign="top" style="padding-right:10px; padding-left:10px;">
<br/>';
// Are they logged in?
if ($context['user']['is_logged'])
{
// Show the total time logged in?
if (!empty($context['user']['total_time_logged_in']))
{
echo '
', $txt['totalTimeLogged1'];
// If days is just zero, don't bother to show it.
if ($context['user']['total_time_logged_in']['days'] > 0)
echo $context['user']['total_time_logged_in']['days'] . $txt['totalTimeLogged2'];
// Same with hours - only show it if it's above zero.
if ($context['user']['total_time_logged_in']['hours'] > 0)
echo $context['user']['total_time_logged_in']['hours'] . $txt['totalTimeLogged3'];
// But, let's always show minutes - Time wasted here: 0 minutes ;).
echo $context['user']['total_time_logged_in']['minutes'], $txt['totalTimeLogged4'], '<br />';
}
// Is the forum in maintenance mode?
if ($context['in_maintenance'] && $context['user']['is_admin'])
echo '
<b>', $txt[616], '</b><br />';
// Are there any members waiting for approval?
if (!empty($context['unapproved_members']))
echo '
', $context['unapproved_members'] == 1 ? $txt['approve_thereis'] : $txt['approve_thereare'], ' <a href="', $scripturl, '?action=viewmembers;sa=browse;type=approve">', $context['unapproved_members'] == 1 ? $txt['approve_member'] : $context['unapproved_members'] . ' ' . $txt['approve_members'], '</a> ', $txt['approve_members_waiting'], '<br />';
}
// Otherwise they're a guest - this time ask them to either register or login - lazy bums...
else
{
echo '
<script language="JavaScript" type="text/javascript" src="', $settings['default_theme_url'], '/sha1.js"></script>
<form action="', $scripturl, '?action=login2" method="post" accept-charset="', $context['character_set'], '" style="margin: 3px 1ex 1px 0;"', empty($context['disable_login_hashing']) ? ' onsubmit="hashLoginPassword(this, \'' . $context['session_id'] . '\');"' : '', '>
<input type="text" name="user" size="10" /> <input type="password" name="passwrd" size="10" />
<select name="cookielength">
<option value="60">', $txt['smf53'], '</option>
<option value="1440">', $txt['smf47'], '</option>
<option value="10080">', $txt['smf48'], '</option>
<option value="43200">', $txt['smf49'], '</option>
<option value="-1" selected="selected">', $txt['smf50'], '</option>
</select>
<input type="submit" value="', $txt[34], '" /><br />
<span class="middletext">', $txt['smf52'], '</span>
<input type="hidden" name="hash_passwrd" value="" />
</form>
<br/><br/>';
}
echo '
</td>
</tr>
<tr id="upshrinkHeader2"', empty($options['collapse_header']) ? '' : ' style="display: none;"', '>
<td colspan="3" class="memberbardivbottom">';
// color selection box
if(isset($settings['allow_color_change']) && $settings['allow_color_change'] == 'box')
echo '
<div style="position: relative; bottom: 13px; right:15px; float:right; ">
<form action="', $scripturl, '" method="post" class="smalltext">
<select name="options[theme_color]">
<option value="lightblue" ' ,$settings['theme_main_color'] == 'lightblue' ? 'selected="selected"': '', '>Light Blue</option>
<option value="lightnavy" ' ,$settings['theme_main_color'] == 'lightnavy' ? 'selected="selected"': '', '>Light Navy</option>
<option value="lightsilver" ' ,$settings['theme_main_color'] == 'lightsilver' ? 'selected="selected"': '', '>Light Silver</option>
<option value="lightturquoise" ' ,$settings['theme_main_color'] == 'lightturquoise' ? 'selected="selected"': '', '>Light Turquoise</option>
<option value="lightgreen" ' ,$settings['theme_main_color'] == 'lightgreen' ? 'selected="selected"': '', '>Light Green</option>
<option value="lightolive" ' ,$settings['theme_main_color'] == 'lightolive' ? 'selected="selected"': '', '>Light Olive</option>
<option value="lightgolden" ' ,$settings['theme_main_color'] == 'lightgolden' ? 'selected="selected"': '', '>Light Golden</option>
<option value="lightbrown" ' ,$settings['theme_main_color'] == 'lightbrown' ? 'selected="selected"': '', '>Light Brown</option>
<option value="lightred" ' ,$settings['theme_main_color'] == 'lightred' ? 'selected="selected"': '', '>Light Red</option>
<option value="lightrose" ' ,$settings['theme_main_color'] == 'lightrose' ? 'selected="selected"': '', '>Light Rose</option>
<option value="lightlilac" ' ,$settings['theme_main_color'] == 'lightlilac' ? 'selected="selected"': '', '>Light Lilac</option>
<option value="lightviolet" ' ,$settings['theme_main_color'] == 'lightviolet' ? 'selected="selected"': '', '>Light Violet</option>
</select>
<input type="submit" name="submit" value="Change" style="width: 11ex;" />
</form>
</div>';
if(isset($settings['allow_color_change']) && $settings['allow_color_change'] == 'bars')
echo '
<div style="position: relative; bottom: 15px; right:15px; float:right; ">
<form action="', $scripturl, '" method="post" class="smalltext">
<input style="border: solid 2px #6699CC; background-color: #6699CC; color: #6699CC; width: 20px; font-size: 1px;" type="submit" value="lightblue" name="options[theme_color]"/>
<input style="border: solid 2px #5371AD; background-color: #5371AD; color: #5371AD; width: 20px; font-size: 1px;" type="submit" value="lightnavy" name="options[theme_color]"/>
<input style="border: solid 2px #6C7F93; background-color: #6C7F93; color: #6C7F93; width: 20px; font-size: 1px;" type="submit" value="lightsilver" name="options[theme_color]"/>
<input style="border: solid 2px #53ADAD; background-color: #53ADAD; color: #53ADAD; width: 20px; font-size: 1px;" type="submit" value="lightturquoise" name="options[theme_color]"/>
<input style="border: solid 2px #4DB45D; background-color: #4DB45D; color: #4DB45D; width: 20px; font-size: 1px;" type="submit" value="lightgreen" name="options[theme_color]"/>
<input style="border: solid 2px #93A659; background-color: #93A659; color: #93A659; width: 20px; font-size: 1px;" type="submit" value="lightolive" name="options[theme_color]"/>
<input style="border: solid 2px #D8A259; background-color: #D8A259; color: #D8A259; width: 20px; font-size: 1px;" type="submit" value="lightgolden" name="options[theme_color]"/>
<input style="border: solid 2px #a67259; background-color: #a67259; color: #a67259; width: 20px; font-size: 1px;" type="submit" value="lightbrown" name="options[theme_color]"/>
<input style="border: solid 2px #E15050; background-color: #E15050; color: #E15050; width: 20px; font-size: 1px;" type="submit" value="lightred" name="options[theme_color]"/>
<input style="border: solid 2px #D47BC5; background-color: #D47BC5; color: #D47BC5; width: 20px; font-size: 1px;" type="submit" value="lightrose" name="options[theme_color]"/>
<input style="border: solid 2px #A185D6; background-color: #A185D6; color: #A185D6; width: 20px; font-size: 1px;" type="submit" value="lightlilac" name="options[theme_color]"/>
<input style="border: solid 2px #7F88B2; background-color: #7F88B2; color: #7F88B2; width: 20px; font-size: 1px;" type="submit" value="lightviolet" name="options[theme_color]"/>
</form>
</div>';
echo '
</td>
</tr>
</table>
</div>';
// End TP user info/news section
}
if(!empty($settings['custom_global_html']))
echo '
<div align="center" style="width: 90%; margin-left: auto; margin-right: auto; margin-top: 10px; border: 0px solid;" class="middletext">
', $settings['custom_global_html'], '
</div>';
// The main content should go here. A table is used because IE 6 just can't handle a div.
echo '<div id="bodyarea" style="padding: 0px 8px 0px 8px;">
<table width="100%" cellpadding="0" cellspacing="0" border="0"><tr>';
// TinyPortal integrated bars
if($context['TPortal']['leftbar'])
{
echo '<td width="' ,$context['TPortal']['leftbar_width'], '" style="padding: ' , isset($context['TPortal']['padding']) ? $context['TPortal']['padding'] : '4' , 'px; background-color: transparent; padding-top: 4px;" valign="top">
<div id="leftbarHeader"', empty($options['collapse_leftbar']) ? '' : ' style="display: none;"', ' style="padding-top: 5px; width: ' ,$context['TPortal']['leftbar_width'], 'px;">';
TPortal_sidebar('left');
echo '</div></td>';
}
echo '<td width="100%" align="left" valign="top" style="padding-top: 10px; padding-bottom: 10px;">';
if($context['TPortal']['centerbar'])
echo '<div>' , TPortal_sidebar('center') , '</div>';
}
function template_main_below()
{
global $context, $settings, $options, $scripturl, $txt;
echo '</td>';
// TinyPortal integrated bars
if($context['TPortal']['rightbar']){
echo '<td style="padding: ' , isset($context['TPortal']['padding']) ? $context['TPortal']['padding'] : '4' , 'px; background-color: transparent; padding-top: 4px;" valign="top" align="right">
<div id="rightbarHeader"', empty($options['collapse_rightbar']) ? '' : ' style="display: none;"', ' style="width: ' ,$context['TPortal']['rightbar_width'], 'px; text-align: left; padding-top: 5px;">';
TPortal_rightbar();
echo '</div></td>';
}
echo '</tr></table></div>';
// Show the "Powered by" and "Valid" logos, as well as the copyright. Remember, the copyright must be somewhere!
echo '
<div id="footerarea" style="text-align: center; padding-bottom: 1ex;', $context['browser']['needs_size_fix'] && !$context['browser']['is_ie6'] ? ' width: 100%;' : '', '">
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
function smfFooterHighlight(element, value)
{
element.src = smf_images_url + "/" + (value ? "h_" : "") + element.id + ".gif";
}
// ]]></script>
<table cellspacing="0" cellpadding="3" border="0" align="center" width="100%">
<tr>
<td width="28%" valign="middle" align="', !$context['right_to_left'] ? 'right' : 'left', '">
<a href="http://www.mysql.com/" target="_blank"><img id="powered-mysql" src="', $settings['images_url'], '/powered-mysql.gif" alt="', $txt['powered_by_mysql'], '" width="54" height="20" style="margin: 5px 16px;" onmouseover="smfFooterHighlight(this, true);" onmouseout="smfFooterHighlight(this, false);" /></a>
<a href="http://www.php.net/" target="_blank"><img id="powered-php" src="', $settings['images_url'], '/powered-php.gif" alt="', $txt['powered_by_php'], '" width="54" height="20" style="margin: 5px 16px;" onmouseover="smfFooterHighlight(this, true);" onmouseout="smfFooterHighlight(this, false);" /></a>
</td>
<td valign="middle" align="center" style="white-space: nowrap;">
', theme_copyright(), ' <span class="smalltext">| ', tportal_version(), '</span>
<br/><br/>';
if(isset($settings['custom_copyright']))
echo '<span class="smalltext">', $settings['custom_copyright'],'</span>';
echo'</td>
<td width="28%" valign="middle" align="', !$context['right_to_left'] ? 'left' : 'right', '">
<a href="http://validator.w3.org/check/referer" target="_blank"><img id="valid-xhtml10" src="', $settings['images_url'], '/valid-xhtml10.gif" alt="', $txt['valid_xhtml'], '" width="54" height="20" style="margin: 5px 16px;" onmouseover="smfFooterHighlight(this, true);" onmouseout="smfFooterHighlight(this, false);" /></a>
<a href="http://jigsaw.w3.org/css-validator/check/referer" target="_blank"><img id="valid-css" src="', $settings['images_url'], '/valid-css.gif" alt="', $txt['valid_css'], '" width="54" height="20" style="margin: 5px 16px;" onmouseover="smfFooterHighlight(this, true);" onmouseout="smfFooterHighlight(this, false);" /></a>
<span style="float:right; margin-right:10px; font-size:70%;"><b>Dilber MC</b> Theme by <b><a href="http://www.harzem.com/themes/themes.php?theme=dilbermc;color=', $settings['theme_main_color'], '" target="_blank">HarzeM</a></b></span>
</td>
</tr>
</table>';
// Show the load time?
if ($context['show_load_time'])
echo '
<span class="smalltext">', $txt['smf301'], $context['load_time'], $txt['smf302'], $context['load_queries'], $txt['smf302b'], '</span>';
// This is an interesting bug in Internet Explorer AND Safari. Rather annoying, it makes overflows just not tall enough.
if (($context['browser']['is_ie'] && !$context['browser']['is_ie4']) || $context['browser']['is_mac_ie'] || $context['browser']['is_safari'])
{
// The purpose of this code is to fix the height of overflow: auto div blocks, because IE can't figure it out for itself.
echo '
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[';
// Unfortunately, Safari does not have a "getComputedStyle" implementation yet, so we have to just do it to code...
if ($context['browser']['is_safari'])
echo '
window.addEventListener("load", smf_codeFix, false);
function smf_codeFix()
{
var codeFix = document.getElementsByTagName ? document.getElementsByTagName("div") : document.all.tags("div");
for (var i = 0; i < codeFix.length; i++)
{
if ((codeFix[i].className == "code" || codeFix[i].className == "post" || codeFix[i].className == "signature") && codeFix[i].offsetHeight < 20)
codeFix[i].style.height = (codeFix[i].offsetHeight + 20) + "px";
}
}';
else
echo '
var window_oldOnload = window.onload;
window.onload = smf_codeFix;
function smf_codeFix()
{
var codeFix = document.getElementsByTagName ? document.getElementsByTagName("div") : document.all.tags("div");
for (var i = codeFix.length - 1; i > 0; i--)
{
if (codeFix[i].currentStyle.overflow == "auto" && (codeFix[i].currentStyle.height == "" || codeFix[i].currentStyle.height == "auto") && (codeFix[i].scrollWidth > codeFix[i].clientWidth || codeFix[i].clientWidth == 0) && (codeFix[i].offsetHeight != 0 || codeFix[i].className == "code"))
codeFix[i].style.height = (codeFix[i].offsetHeight + 36) + "px";
}
if (window_oldOnload)
{
window_oldOnload();
window_oldOnload = null;
}
}';
echo '
// ]]></script>';
}
// TinyPortal
echo '</div>';
if($context['TPortal']['fixed_width']!=0)
echo '</td></tr></table>';
// end
echo '
</div>
',($context['browser']['is_ie']) ? '</td></tr></table>' : '</div>' , '
</div>';
// The following will be used to let the user know that some AJAX process is running
echo '
<div id="ajax_in_progress" class="ajax_in_progress" style="display: none;', $context['browser']['is_ie'] && !$context['browser']['is_ie7'] ? 'position: absolute;' : '', '">', $txt['ajax_in_progress'], '</div>
</body></html>';
}
// Show a linktree. This is that thing that shows "My Community | General Category | General Discussion"..
function theme_linktree()
{
global $context, $settings, $options;
echo '<div class="nav" style="font-size: 85%; margin-bottom: 2ex; margin-top: 2ex;">';
// Each tree item has a URL and name. Some may have extra_before and extra_after.
foreach ($context['linktree'] as $link_num => $tree)
{
// Show something before the link?
if (isset($tree['extra_before']))
echo $tree['extra_before'];
// Show the link, including a URL if it should have one.
echo '<b>', $settings['linktree_link'] && isset($tree['url']) ? '<a href="' . $tree['url'] . '" class="nav">' . $tree['name'] . '</a>' : $tree['name'], '</b>';
// Show something after the link...?
if (isset($tree['extra_after']))
echo $tree['extra_after'];
// Don't show a separator for the last one.
if ($link_num != count($context['linktree']) - 1)
echo ' > ';
}
echo '</div>';
}
// Show the menu up top. Something like [home] [help] [profile] [logout]...
function template_menu()
{
global $context, $settings, $options, $scripturl, $txt;
// Work out where we currently are.
$current_action = 'home';
if (in_array($context['current_action'], array('admin', 'ban', 'boardrecount', 'cleanperms', 'detailedversion', 'dumpdb', 'featuresettings', 'featuresettings2', 'findmember', 'maintain', 'manageattachments', 'manageboards', 'managecalendar', 'managesearch', 'membergroups', 'modlog', 'news', 'optimizetables', 'packageget', 'packages', 'permissions', 'pgdownload', 'postsettings', 'regcenter', 'repairboards', 'reports', 'serversettings', 'serversettings2', 'smileys', 'viewErrorLog', 'viewmembers')))
$current_action = 'admin';
if (in_array($context['current_action'], array('search', 'admin', 'calendar', 'gallery', 'profile', 'mlist', 'register', 'login', 'help', 'pm', 'forum', 'tpadmin')))
$current_action = $context['current_action'];
if ($context['current_action'] == 'search2')
$current_action = 'search';
if (isset($_GET['dl']))
$current_action = 'dlmanager';
if (isset($_GET['board']) || isset($_GET['topic']))
$current_action = 'forum';
if ($context['current_action'] == 'theme')
$current_action = isset($_REQUEST['sa']) && $_REQUEST['sa'] == 'pick' ? 'profile' : 'admin';
// Dummy place holder, to set the height
echo'
<td align="center" class="menubg" height="30" width="20">
</td>';
// Show the [home] button.
echo'
<td align="center" class="menubg' , $current_action == 'home' ? '2' : '' , '">
<a href="', $scripturl, '">' , $txt[103] , '</a>
</td>';
if($settings['TPortal_front_type']!='boardindex')
// Show the [forum] button.
echo'
<td align="center" class="menubg' , $current_action == 'forum' ? '2' : '' , '">
<a href="', $scripturl, '?action=forum">'.$txt['tp-forum'].'</a>
</td>';
// Show the [help] button.
echo'
<td align="center" class="menubg' , $current_action == 'help' ? '2' : '' , '">
<a href="', $scripturl, '?action=help">' , $txt[119] , '</a>
</td>';
// How about the [search] button?
if ($context['allow_search'])
echo'
<td align="center" class="menubg' , $current_action == 'search' ? '2' : '' , '">
<a href="', $scripturl, '?action=search">' , $txt[182] , '</a>
</td>';
// Is the user allowed to administrate at all? ([admin])
if ($context['allow_admin'])
echo'
<td align="center" class="menubg' , $current_action == 'admin' ? '2' : '' , '">
<a href="', $scripturl, '?action=admin">' , $txt[2] , '</a>
</td>';
// Edit Profile... [profile]
if ($context['allow_edit_profile'])
echo'
<td align="center" class="menubg' , $current_action == 'profile' ? '2' : '' , '">
<a href="', $scripturl, '?action=profile">' , $txt[79] , '</a>
</td>';
// Go to PM center... [pm]
if ($context['user']['is_logged'] && $context['allow_pm'])
echo'
<td align="center" class="menubg' , $current_action == 'pm' ? '2' : '' , '">
<a href="', $scripturl, '?action=pm">' , $txt['pm_short'] , ' ', $context['user']['unread_messages'] > 0 ? '[<strong>'. $context['user']['unread_messages'] . '</strong>]' : '' , '</a>
</td>';
// Show the [gallery] button.
echo'
<td align="center" class="menubg' , $current_action == 'help' ? '2' : '' , '">
<a href="', $scripturl, '?action=gallery">' , $txt['smfgallery_menu'] , '</a>
</td>';
// The [calendar]!
if ($context['allow_calendar'])
echo'
<td align="center" class="menubg' , $current_action == 'calendar' ? '2' : '' , '">
<a href="', $scripturl, '?action=calendar">' , $txt['calendar24'] , '</a>
</td>';
// the [member] list button
if ($context['allow_memberlist'])
echo'
<td align="center" class="menubg' , $current_action == 'mlist' ? '2' : '' , '">
<a href="', $scripturl, '?action=mlist">' , $txt[331] , '</a>
</td>';
// If the user is a guest, show [login] button.
if ($context['user']['is_guest'])
echo'
<td align="center" class="menubg' , $current_action == 'login' ? '2' : '' , '">
<a href="', $scripturl, '?action=login">' , $txt[34] , '</a>
</td>';
// If the user is a guest, also show [register] button.
if ($context['user']['is_guest'])
echo'
<td align="center" class="menubg' , $current_action == 'register' ? '2' : '' , '">
<a href="', $scripturl, '?action=register">' , $txt[97] , '</a>
</td>';
// Otherwise, they might want to [logout]...
if ($context['user']['is_logged'])
echo'
<td align="center" class="menubg' , $current_action == 'logout' ? '2' : '' , '">
<a href="', $scripturl, '?action=logout;sesc=', $context['session_id'], '">' , $txt[108] , '</a>
</td>';
// Dummy place holder, to end things
echo'
<td align="center" class="menubg" width="20">
</td>';
// TinyPortal
if($context['TPortal']['leftbar'])
echo '<td style="padding-left: 1ex;"><a href="javascript:void(0);" onclick="shrinkHeaderLeftbar(!current_leftbar); return false;"><img id="upshrinkLeftbar" src="', $settings['images_url'], '/', empty($options['collapse_leftbar']) ? 'upshrink.gif' : 'upshrink2.gif', '" alt="*" title="', $txt['upshrink_description'], '" style="margin: 2px 0;" border="0" /></a><img id="upshrinkTempLeftbar" src="', $settings['images_url'], '/blank.gif" alt="" style="margin-right: 0ex;" /></td>';
if($context['TPortal']['rightbar'])
echo '<td style="padding-left: 1ex;"><a href="javascript:void(0);" onclick="shrinkHeaderRightbar(!current_rightbar); return false;"><img id="upshrinkRightbar" src="', $settings['images_url'], '/', empty($options['collapse_rightbar']) ? 'upshrink.gif' : 'upshrink2.gif', '" alt="*" title="', $txt['upshrink_description'], '" style="margin: 2px 0;" border="0" /></a><img id="upshrinkTempRightbar" src="', $settings['images_url'], '/blank.gif" alt="" style="margin-right: 0ex;" /></td>';
// TinyPortal end
echo '
</tr>
</table>';
}
// Generate a strip of buttons.
function template_button_strip($button_strip, $direction = 'top', $force_reset = false, $custom_td = '')
{
global $settings, $buttons, $context, $txt, $scripturl;
// Create the buttons...
foreach ($button_strip as $key => $value)
{
if (isset($value['test']) && empty($context[$value['test']]))
{
unset($button_strip[$key]);
continue;
}
elseif (!isset($buttons[$key]) || $force_reset)
$buttons[$key] = '<a href="' . $value['url'] . '" ' .( isset($value['custom']) ? $value['custom'] : '') . '>' . $txt[$value['text']] . '</a>';
$button_strip[$key] = $buttons[$key];
}
if (empty($button_strip))
return '<td> </td>';
echo '
<td class="', $direction == 'top' ? 'main' : 'main', 'strip_first', '"> </td>
<td class="', $direction == 'top' ? 'main' : 'main', 'strip">', implode(' | ', $button_strip) , '</td>
<td class="', $direction == 'top' ? 'main' : 'main', 'strip_last' , '"> </td>';
}
?>
if ((!$context['user']['is_guest']) && $context['user']['is_logged'])
Quote from: CTwiz on July 07, 2008, 10:17:15 AM
You'll be needing to manually edit your files in your theme. :)
Quote from: CTwiz on July 07, 2008, 12:07:02 PM
mm, you'll be needing to edit the files (via FTP) in:
/Sources
and
/Themes/*your_theme*/
Look in the install.xml to find the files that the modification itself edits.
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
if (!empty($context['users_online_today'])
Quote from: DirtRider on June 23, 2008, 11:57:54 PM
Ok I tried the version 1.4.0 and it installed. I get the following stats from my board
Most Online Today: 16. Most Online Ever: 16 (Yesterday at 09:02:45 PM)
Quote from: ranKoto on July 19, 2008, 11:13:49 AMQuote from: DirtRider on June 23, 2008, 11:57:54 PM
Ok I tried the version 1.4.0 and it installed. I get the following stats from my board
Most Online Today: 16. Most Online Ever: 16 (Yesterday at 09:02:45 PM)
hi DirtRider
can you tell me where did you get that stat ? is that from the mod ?
i actually want to have that "Most Online Ever" in this mod
im using SMF 1.1.4 and users online today mod ver. 1.4.0
Quote from: jaccione on July 01, 2008, 09:35:26 AM
Posted this earlier up, this will hide it to only admin, you can probably change the permisson to whatever level you want.
just wrap your block of code in this
if ($context['user']['is_admin'])
{
the code for the mod here
}
Quote from: optimushunk on July 28, 2008, 09:39:51 AM
sorry for the question but is there anyone who would help me with the problem shown in the image ??? Please help me out.
Thanks.
Quote// Load the users online right now.
$result = db_query("
SELECT
lo.ID_MEMBER, lo.logTime, lo.url, 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__);
QuoteError message '1024: Canview method for getMembersOnlineTodayStats() function is not allowed'
Quoteif ($context['user']['is_admin'])
{
// 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'], '" />', '
</td>
<td class="windowbg2" width="100%">';
echo '
<div class="smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo '
(', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo '<br />', implode(', ', $context['list_users_online_today']);
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '<br />[' . implode('] [', $context['membergroups']) . ']';
}
echo '</div>';
echo '</td>';
echo '</tr>';
}
Quote
The package you are trying to download or install is either corrupt or not compatible with this version of SMF.
Quote from: optimushunk on July 29, 2008, 07:48:46 PM
Please solve this problem:- http://www.simplemachines.org/community/index.php?topic=55513.msg1631641#msg1631641
BoardIndex.template.php attached in this post:- http://www.simplemachines.org/community/index.php?topic=55513.msg1634616#msg1634616
Please help me out, I am almost finished with my forum and just this tiny bits remaining. Kindly help me.
Thank you.
Quote from: memyselfandI on August 04, 2008, 02:48:53 AM
Is anyone supporting this mod? I have the same problem as someone else that was never answered
Undefined index: uot_users_online_today
8: Undefined index: uot_total
8: Undefined index: uot_total
8: Undefined index: uot_hidden
loadLanguage('UsersOnlineToday');
// Retrieve a list and several other statistics of the users online during a specific period.
function getMembersOnlineTodayStats($membersOnlineTodayOptions)
{
global $smcFunc, $context, $scripturl, $user_info, $modSettings, $txt;
Quote from: Otterdam on August 04, 2008, 12:20:24 PM
If you want to fix it, open up Subs-MembersOnlineToday.php
Cut the line at the end of the file:Code SelectloadLanguage('UsersOnlineToday');
And paste it below the following code, near the start of the file:Code Select// Retrieve a list and several other statistics of the users online during a specific period.
function getMembersOnlineTodayStats($membersOnlineTodayOptions)
{
global $smcFunc, $context, $scripturl, $user_info, $modSettings, $txt;
Quote from: memyselfandI on August 04, 2008, 02:48:53 AM
Is anyone supporting this mod? I have the same problem as someone else that was never answered
Undefined index: uot_users_online_today
8: Undefined index: uot_total
8: Undefined index: uot_total
8: Undefined index: uot_hidden
Quote8: Undefined index: uot_yesterday
File: /home/james2/public_html/forum/Sources/Subs-MembersOnlineToday.php
Line: 135
Quote from: F.L.A.M.E.R on August 15, 2008, 05:36:17 AM
see at the base, it shows all the users who came online "Today".
Quote from: stfox100 on August 19, 2008, 02:37:20 PM
Although ccbtimewiz seems to be trying to help out as best he can, I haven't seen the author reply to a post or help in any manner in a long time. Most posts just go unanswered. I consider this mod a dead end and not worth your time.
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';
QuoteApply Filter: Only show the error messages of this member Expat Today at 08:32:48 PM
Apply Filter: Only show the error messages of this IP address 203.177.74.137 Apply Filter: Only show the error messages of this session e59dbc688052e06413fb8fe8c8629bf1
Apply Filter: Only show the error messages of this URL http://expat.heyjoe.ph/index.php
Apply Filter: Only show the errors with the same message
8: Undefined index: uot_hidden
File: /home/heyjoe/public_html/philippine-expat-community/Themes/default/BoardIndex.template.php (main sub template - eval?)
Line: 427
Apply Filter: Only show the error messages of this member Expat Today at 08:32:48 PM
Apply Filter: Only show the error messages of this IP address 203.177.74.137 Apply Filter: Only show the error messages of this session e59dbc688052e06413fb8fe8c8629bf1
Apply Filter: Only show the error messages of this URL http://expat.heyjoe.ph/index.php
Apply Filter: Only show the errors with the same message
8: Undefined index: uot_visible
File: /home/heyjoe/public_html/philippine-expat-community/Themes/default/BoardIndex.template.php (main sub template - eval?)
Line: 427
Apply Filter: Only show the error messages of this member Expat Today at 08:32:48 PM
Apply Filter: Only show the error messages of this IP address 203.177.74.137 Apply Filter: Only show the error messages of this session e59dbc688052e06413fb8fe8c8629bf1
Apply Filter: Only show the error messages of this URL http://expat.heyjoe.ph/index.php
Apply Filter: Only show the errors with the same message
8: Undefined index: uot_total
File: /home/heyjoe/public_html/philippine-expat-community/Themes/default/BoardIndex.template.php (main sub template - eval?)
Line: 425
Quote from: cubetgio on August 25, 2008, 04:42:03 AM
Is there somebody to tell me how to uninstall uot mod manually ?
The link "uninstall" is not displayed anymore in my package browser...
Thanks you!
Quote from: searchgr on August 24, 2008, 01:26:06 AM
How can i remove the number of the hidden members?
Quote from: Sickthing on August 24, 2008, 08:45:04 AM
I love this mod but I'm having trouble with it on one of my boards. After installing it I started seeing this at the top of the page: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';
Quote from: tk2012 on August 26, 2008, 01:52:28 PM
I'm running v2.0 b3.1
I just received about 40 errors in the last 24 hours that are all the same...(ok, I counted. It was 48 errors. Just wanted to make sure I wasn't exagerating! Seems I was being conservative.)
Quote from: Carceri on August 27, 2008, 03:56:28 AMQuote from: tk2012 on August 26, 2008, 01:52:28 PM
I'm running v2.0 b3.1
I just received about 40 errors in the last 24 hours that are all the same...(ok, I counted. It was 48 errors. Just wanted to make sure I wasn't exagerating! Seems I was being conservative.)
1.5.2
What version of the mod are you using, because the line numbers are not the same as in the latest version I have here.
Quote from: tk2012 on August 30, 2008, 04:37:41 PM
1.5.2
Quote from: Geezer on September 04, 2008, 05:07:15 PM
hi I am running smf1.15 and installed uot 1.4, it installed ok but I am getting this at top of my board (see attachment), any idea why anyone please?
Quote from: feelingshehides on September 13, 2008, 12:03:42 PM
Hello, this mod still not compatible with 1.1.6 ?
I tried to install but just gives me an incompatible error :(
Quote from: Powerbob on September 17, 2008, 08:24:07 AM
Hi Carceri, any chance you will be updating your mod to Beta 4 soon?
Quote from: TroyG on September 11, 2008, 11:54:07 PM
Is there a option I can select to not show this feature to regular members, I want the admin's only to be able to see this.
You guys do a great job !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Thanks Troy
Quote from: TroyG on September 17, 2008, 07:22:16 PMQuote from: TroyG on September 11, 2008, 11:54:07 PM
Is there a option I can select to not show this feature to regular members, I want the admin's only to be able to see this.
You guys do a great job !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Thanks Troy
bump
Quote from: gxpgreg on April 07, 2008, 08:40:15 PM
After running through previous posts I checked my modifications.english.php and the stats.english.php and I have the required lines of code in there that were previously mentioned. Still just getting the : 7 (: 7, : 0) without the words Total, Visible and Hidden.
Any ideas would really be appreciated thanks.
Quote from: Carceri on September 14, 2008, 06:29:32 PMQuote from: feelingshehides on September 13, 2008, 12:03:42 PM
Hello, this mod still not compatible with 1.1.6 ?
I tried to install but just gives me an incompatible error :(
I have successfully installed it on 1.1.6. Is this a problem for other people as well?
Quote from: Exterminator2006 on August 31, 2008, 03:23:15 PM
i use this and perfect working :)
Quote from: Exterminator2006 on September 19, 2008, 05:15:48 PMQuote from: Exterminator2006 on August 31, 2008, 03:23:15 PM
i use this and perfect working :)
http://www.simplemachines.org/community/index.php?action=dlattach;topic=55513.0;attach=66773
Too in 1.1.6 Perfect :)
QuoteType Action Description
1. Execute Modification ./Sources/BoardIndex.php Test failed
2. Execute Modification ./Themes/classic/BoardIndex.template.php Test failed
3. Extract File ./Sources/Subs-MembersOnlineToday.php
4. Extract File ./Themes/classic/languages/MembersOnlineToday.english.php
Quote from: ruipedrola on September 22, 2008, 10:09:40 PM
Hi I have your mod working great in 3 boards. Now i need to change a little bit. I need change the list of last 24 hours users to 48 hours or 72 hours.... how it´s possible make this? Thanks in advance
Quote from: F4r4Zm0In on September 23, 2008, 02:01:20 PM
I am using smf 1.1.6, using "classic" theme which comes with the default smf installation
while installing
Users Online Today 1.5.4
i have got this
Quote from: W. Riker on September 20, 2008, 05:49:38 AM
How could i set things in way that under statistic who was online today there is also a statistic "Most members ever online in one day was ???, last accomplished on ???"
Help needed.
Quote from: W. Riker on September 24, 2008, 06:17:30 PMQuote from: W. Riker on September 20, 2008, 05:49:38 AM
How could i set things in way that under statistic who was online today there is also a statistic "Most members ever online in one day was ???, last accomplished on ???"
Help needed.
Is it possible with this mod at all?
$context += getMembersOnlineStats($membersOnlineOptions);
in boardindex.phpQuote from: rarach on October 09, 2008, 10:13:31 AM
I apologize if this has already been asked, but 50 some pages is a lot to sift through.. >.<
I have installed your mod, and it works great on one of the themes I have been tweaking myself for personal use, but it does not seem to work on the default.
I tried doing the manual install as well, but I can not findCode Select$context += getMembersOnlineStats($membersOnlineOptions);
in boardindex.php
What can I do?
Quote from: rarach on October 10, 2008, 08:32:24 PM
....it just will not appear on the default theme........
The theme that the mod works on is dark day.
Quote from: rarach on October 10, 2008, 08:32:24 PM
We are using the helios multicolor theme. The theme that the mod works on is dark day.
Quote from: Frozt on October 02, 2008, 07:21:07 AM
I install the version 1.4.0 in smf 1.1.6 but after logoff I can´t see the list of users in "Users Logged In Today", I see only the number of users logged today:
Total: xx (Visible: xx, Hidden: xx)
but not the list of name of that users
I search in all the admin settings and I can´t find an option for allow see the users logged today for visitors, I dont know if there are this option or if visitors cant see the list of users. When I login I can see the list of users logged today.
Is there an option for active it to see the list the visitors too?
In the Users Online module I can see the users logged if I loged or not
I have the default theme in the forum
Quote from: rarach on October 12, 2008, 03:52:35 PM
Thanks so much for your help! I finally got it to work after going through and re-doing the manual codes. ;D
Quote from: Sabre™ on October 10, 2008, 07:38:06 PM
Check you have the correct version, as that line is not installed in SMF 1.1.6
QuoteToday at 11:06:50 AM
72.34.188.13 cf25edd15d333ba502f6d46ce19ef1cb
http://www.oakbendnevada.com/forum/index.php
8: Undefined index: uot_users_online_today
File: /home/content/o/a/k/oakbendnevada/html/forum/Themes/SMF_Grunge/BoardIndex.template.php (main sub template - eval?)
Line: 443
Troy & Kristi Today at 11:06:50 AM
72.34.188.13 cf25edd15d333ba502f6d46ce19ef1cb
http://www.oakbendnevada.com/forum/index.php
8: Undefined index: uot_users_online_today
File: /home/content/o/a/k/oakbendnevada/html/forum/Themes/SMF_Grunge/BoardIndex.template.php (main sub template - eval?)
Line: 440
// If they are logged in, but statistical information is off... show a personal message bar.
// Users online today
echo '
<div class="infocenter_section">
<h4 class="headerpadding titlebg">', $txt['uot_users_online_today'], '</h4>
<div class="windowbg">
<p class="section">
<img src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['uot_users_online_today'], '" />
</p>
<div class="windowbg2 sectionbody">
<div class="smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo '<br />', implode(', ', $context['list_users_online_today']);
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '<br />[' . implode('] [', $context['membergroups']) . ']';
}
echo '
</div>
</div>
</div>
</div>';
Quote from: F.L.A.M.E.R on November 09, 2008, 10:19:07 AMthank you for the fast reply!
@DartaWeb
It is by default that the guests cannot see it. Its only the logged in users.
Quote from: F.L.A.M.E.R on November 09, 2008, 10:32:40 AM
Can you tell me which language is that, i am trying to translate the page to help you out. :)
Quote from: F.L.A.M.E.R on November 09, 2008, 10:32:40 AM
Can you tell me which language is that, i am trying to translate the page to help you out. :)
Quote from: F.L.A.M.E.R on November 09, 2008, 10:19:07 AM
@ psynx
Which package are you using, go on the download page, choose the SMF version for the pack you are using, and then check the manual edits in there.
QuoteMove the included file "Subs-MembersOnlineToday.php" to "./Sources".
Move the included file "MembersOnlineToday.english.php" to "./Themes/default/languages".
Quote
Find:
// Users online today
echo '
<div class="infocenter_section">
<h4 class="headerpadding titlebg">', $txt['uot_users_online_today'], '</h4>
<div class="windowbg">
<p class="section">
<img src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['uot_users_online_today'], '" />
</p>
<div class="windowbg2 sectionbody">
<div class="smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo '<br />', implode(', ', $context['list_users_online_today']);
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '<br />[' . implode('] [', $context['membergroups']) . ']';
}
echo '
</div>
</div>
</div>
</div>';
// If they are logged in, but statistical information is off... show a personal message bar.
Quote
Replace: // If they are logged in, but statistical information is off... show a personal message bar.
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'], ')';
if (!$context['user']['is_guest'])
// 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']);
// 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']);
QuoteParse error: syntax error, unexpected '!', expecting '(' in .../Themes/XDEquinoxG1/BoardIndex.template.php on line 750
741: <td class="row111" width="100%">';
742:
743: echo '
744: <div class="smalltext">';
745:
746: echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
747: echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';
748:
749: // Assuming there ARE users online... each user in users_online has an id, username, name, group, href, and link.
750: if !empty($context['users_online_today'])
751: echo '<br />', implode(', ', $context['list_users_online_today']);
752: echo '
753: <br />', $context['show_stats'] && !$settings['show_sp1_info'] ? '
754: <a href="' . $scripturl . '?action=stats">' . $txt['smf223'] . '</a>' : '', '
Quote from: katb on November 22, 2008, 08:43:08 AM
i am using smf 1.1.7 when i try to install package manager it is showing following error
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.
Type Action Description
1. Execute Modification ./Sources/BoardIndex.php Test failed
2. Execute Modification ./Themes/default/BoardIndex.template.php Test failed
after this i tried manual installation i tried to $context += getMembersOnlineStats($membersOnlineOptions); in ./Sources/BoardIndex.php , but i am not able to see this , as per manual installation it is showing add some lines after this variable, but i can't . Any help appreciated . Thanks in advance .
// Get the user online today list.
require_once($sourcedir . '/Subs-MembersOnlineToday.php');
$membersOnlineTodayOptions = array(
'sort' => 'login_time',
'reverse_sort' => true,
'period' => 'current_day',
'canview' => 'registered',
);
$context += getMembersOnlineTodayStats($membersOnlineTodayOptions);
Quote from: JimM on November 22, 2008, 09:23:24 PM
@katb - you are using the wrong file. Be sure when you use the parser you click the 1.4.0 file for 1.1.7. If you are seeing those statements you are parsing 1.5.4 which is for 2.0 Beta 4.
Quote from: JimM on November 25, 2008, 11:30:46 PM
You quoted katb's post, but you didn't see my post right after it?Quote from: JimM on November 22, 2008, 09:23:24 PM
@katb - you are using the wrong file. Be sure when you use the parser you click the 1.4.0 file for 1.1.7. If you are seeing those statements you are parsing 1.5.4 which is for 2.0 Beta 4.
You downloaded or are parsing the wrong file!
Quote from: JimM on November 22, 2008, 09:23:24 PM
@katb - you are using the wrong file. Be sure when you use the parser you click the 1.4.0 file for 1.1.7. If you are seeing those statements you are parsing 1.5.4 which is for 2.0 Beta 4.
Quote from: katb on November 22, 2008, 08:43:08 AM
after this i tried manual installation i tried to $context += getMembersOnlineStats($membersOnlineOptions); in ./Sources/BoardIndex.php , but i am not able to see this , as per manual installation it is showing add some lines after this variable, but i can't . Any help appreciated . Thanks in advance .
Quote from: GMCbris on December 22, 2008, 05:58:40 AMI guess not
Hi
is there a way to add all the guests that visit and add to the stats?
Cheers
GMC
Quote from: GMCbris on January 01, 2009, 08:05:46 AMQuote from: GMCbris on December 22, 2008, 05:58:40 AMI guess not
Hi
is there a way to add all the guests that visit and add to the stats?
Cheers
GMC
Happy New Year one and all
QuoteInstalling this package will perform the following actions:
Type Action Description
1. Execute Modification ./Sources/BoardIndex.php Test failed
2. Execute Modification ./Themes/default/BoardIndex.template.php Test failed
3. Extract File ./Sources/Subs-MembersOnlineToday.php
4. Extract File ./Themes/default/languages/MembersOnlineToday.english.php
Quote from: JimM on January 23, 2009, 03:07:17 PM
If you are using this mod with 1.1.7, you want to download 1.4.0. Version 1.5.4 is only for SMF 2.0.
Quote from: aw06 on January 28, 2009, 01:19:20 AM
Is their a log i can see ? would like to see the users online for each day that has passed ?
Quote from: aw06 on January 28, 2009, 01:48:51 PM
hmm ,. sorry about the mix up .. my question was with regards to the mod
423 <td class="windowbg2" width="100%">';
424
425 if ($context['show_who'])
426 echo '
427 <a href="', $scripturl, '?action=who">';
428
429 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'];
Quote
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 11:45:37
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 11:44:04
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 09:32:57
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 09:32:34
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 09:15:18
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:51:40
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:51:11
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:43:54
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:43:38
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:39:26
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:37:55
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:32:13
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:27:54
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:21:55
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:21:32
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:09:41
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:08:46
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 08:08:17
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
today at 07:50:25
xx.xx.xxx.xxx marcus
8: Undefined index: users
File: /srv/www/xxxxx/xxxxxx/httpdocs/Themes/igoh113/BoardIndex.template.php (main sub template - eval?)
Linea: 429
Quote from: blondeamon on January 07, 2009, 07:55:42 PM
First of all congratulations for the mod , i have been using it for months and its perfect.
But you know what would be even more wonderful and make it 10 times better? If you could store that daily number of members somewhere. The perfect place would be in the stats as an extra column storing the number of members logged every day.
Can that be implemented? It would be awesome as it is actually the number of unique visitors our forums get every day. Let me know if it can be done or not.....many people would want that extra feat but we dont want to be a burden if u are busy.
Friendly , Jim
Quote from: mcrat on February 03, 2009, 10:07:49 PMQuote from: blondeamon on January 07, 2009, 07:55:42 PM
First of all congratulations for the mod , i have been using it for months and its perfect.
But you know what would be even more wonderful and make it 10 times better? If you could store that daily number of members somewhere. The perfect place would be in the stats as an extra column storing the number of members logged every day.
Can that be implemented? It would be awesome as it is actually the number of unique visitors our forums get every day. Let me know if it can be done or not.....many people would want that extra feat but we dont want to be a burden if u are busy.
Friendly , Jim
I too would love to see something like this added to the mod. Also for it show the highest number ever on the front page, just like it does for Most Online Today.
ie Users Logged in Today: 22. Most Users Logged in Ever: 53 (January 09, 2009)
If any keen developers want to step up to the plate... ;)
Quote from: Roman on February 07, 2009, 07:25:41 AM
Is there a new version in the pipeline?
Compatible to 2.0 RC1
Thanks
Roman
Quote from: SgtMic on February 09, 2009, 12:06:40 AM
It works, but you will need to manually change the code in themes/default/board.template.
Quote1.4.0: SMF 1.1.x
1.5.4: SMF 2.0 series
Quote from: gregahpoa on February 11, 2009, 12:24:46 PM
JimM,
From the Users Online Today mod page under the SMF Mod Site, it states...
Latest Version: 1.5.4
Compatible With: 1.1.5, 1.1.6, 1.1.8, 2.0 Beta 4, 2.0 RC1
It was updated just a couple days ago.
Quote from: psynx on November 13, 2008, 01:13:30 AMI have same problem like psynx on my theme (ferry theme), and on default theme the same problem.
hello,
i have installed this mod but why is it only tells the number of members who are logged in for today? their names are not going to be listed? i want their names to be listed too.
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fd.imagehost.org%2F0510%2Funtitled_9.jpg&hash=6e4f4cf91328266d6b7af8b685c5cad3b7c78104)
Quote from: tom333 on February 13, 2009, 12:25:53 AMQuote from: psynx on November 13, 2008, 01:13:30 AMI have same problem like psynx on my theme (ferry theme), and on default theme the same problem.
hello,
i have installed this mod but why is it only tells the number of members who are logged in for today? their names are not going to be listed? i want their names to be listed too.
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fd.imagehost.org%2F0510%2Funtitled_9.jpg&hash=6e4f4cf91328266d6b7af8b685c5cad3b7c78104)
Whay?
I attached for both thme boardindex.php
thanx in advance.
p.s.-boardindex is defoult theme, boardindex1 is my theme (ferry tema)
<?php
// Version: 1.1; BoardIndex
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="0" 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'], ' &#8226; ', $txt[95], ': ', $context['common_stats']['total_posts'], ' &#8226; ', $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 '
<table border="0" width="100%" class="tborder" cellspacing="' , ($context['browser']['is_ie'] || $context['browser']['is_opera6']) ? '1' : '0' , '" cellpadding="4" style="margin-bottom: 2ex;">
<tr>
<td class="catbg"> ', $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": 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>';
}
/* 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 image),
and boards. (see below.) */
$first = true;
foreach ($context['categories'] as $category)
{
echo '
<div class="tborder" style="margin-top: ' , $first ? '0;' : '1ex;' , '' , $context['browser']['needs_size_fix'] && !$context['browser']['is_ie6'] ? 'width: 100%;' : '', '">
<div class="catbg', $category['new'] ? '2' : '', '" style="padding: 5px 5px 5px 10px;">';
$first = false;
// If this category even can collapse, show a link to collapse it.
if ($category['can_collapse'])
echo '
<a href="', $category['collapse_href'], '" class="collapse_expand">', $category['collapse_image'], '</a>';
echo '
', $category['link'], '
</div>';
// Assuming the category hasn't been collapsed...
if (!$category['is_collapsed'])
{
echo '
<table border="0" width="100%" cellspacing="1" cellpadding="5" class="bordercolor" style="margin-top: 1px;">';
/* 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 ' , !empty($board['children']) ? 'rowspan="2"' : '' , ' 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], '" />';
// 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], '" />';
// No new posts at all! The agony!!
else
echo '<img src="', $settings['images_url'], '/off.gif" alt="', $txt[334], '" title="', $txt[334], '" />';
echo '</a>
</td>
<td 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 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], ' <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 '
<b>', $txt[22], '</b> ', $txt[525], ' ', $board['last_post']['member']['link'] , '<br />
', $txt['smf88'], ' ', $board['last_post']['link'], '<br />
', $txt[30], ' ', $board['last_post']['time'];
echo '
</span>
</td>
</tr>';
// 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 '
<tr>
<td colspan="3" class="windowbg', !empty($settings['seperate_sticky_lock']) ? '3' : '', '">
<span class="smalltext"><b>', $txt['parent_boards'], '</b>: ', implode(', ', $children), '</span>
</td>
</tr>';
}
}
echo '
</table>';
}
echo '
</div>';
}
if ($context['user']['is_logged'])
{
echo '
<table border="0" width="100%" cellspacing="0" cellpadding="5">
<tr>
<td align="', !$context['right_to_left'] ? 'left' : 'right', '" class="smalltext">
<img src="' . $settings['images_url'] . '/new_some.gif" alt="" align="middle" /> ', $txt[333], '
<img src="' . $settings['images_url'] . '/new_none.gif" alt="" align="middle" style="margin-left: 4ex;" /> ', $txt[334], '
</td>
<td align="', !$context['right_to_left'] ? 'right' : 'left', '">';
// Mark read button.
if ($settings['show_mark_read'] && !empty($context['categories']))
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>';
}
// Here's where the "Info Center" starts...
echo '<br />
<div class="tborder" ', $context['browser']['needs_size_fix'] && !$context['browser']['is_ie6'] ? 'style="width: 100%;"' : '', '>
<div class="catbg" style="padding: 6px; vertical-align: middle; ">
<a href="#" onclick="shrinkHeaderIC(!current_header_ic); return false;"><img id="upshrink_ic" src="', $settings['images_url'], '/', empty($options['collapse_header_ic']) ? 'collapse.gif' : 'expand.gif', '" alt="*" title="', $txt['upshrink_description'], '" style="margin-right: 2ex;" align="left" /></a>
', $txt[685], '
</div>
<div id="upshrinkHeaderIC"', empty($options['collapse_header_ic']) ? '' : ' style="display: none;"', '>
<table border="0" width="100%" cellspacing="1" cellpadding="4" class="bordercolor">';
// This is the "Recent Posts" bar.
if (!empty($settings['number_recent_posts']))
{
echo '
<tr>
<td class="titlebg" 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], '" /></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], ' "', $context['latest_post']['link'], '" ', $txt[235], ' (', $context['latest_post']['time'], ')<br />
</div>';
}
// Show lots of posts.
elseif (!empty($context['latest_posts']))
{
echo '
<table cellpadding="0" cellspacing="0" 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="middletext" valign="top"><b>', $post['link'], '</b> ', $txt[525], ' ', $post['poster']['link'], ' (', $post['board']['link'], ')</td>
<td class="middletext" 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="titlebg" 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'], '" /></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>';
}
// Show YaBB SP1 style information...
if ($settings['show_sp1_info'])
{
echo '
<tr>
<td class="titlebg" 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], '" /></a>
</td>
<td class="windowbg2" width="100%">
<span class="middletext">
', $context['common_stats']['total_posts'], ' ', $txt[95], ' ', $txt['smf88'], ' ', $context['common_stats']['total_topics'], ' ', $txt[64], ' ', $txt[525], ' ', $context['common_stats']['total_members'], ' ', $txt[19], '. ', $txt[656], ': <b> ', $context['common_stats']['latest_member']['link'], '</b>
<br /> ' . $txt[659] . ': <b>"' . $context['latest_post']['link'] . '"</b> ( ' . $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>' : '', '
</span>
</td>
</tr>';
}
// "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%">';
echo '
', $context['show_who'] ? '<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'];
// 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 ')';
}
echo $context['show_who'] ? '</a>' : '', '
<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>
<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>';
// Users online today
if ((!$context['user']['is_guest']) && $context['user']['is_logged'])
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>';
// 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="titlebg" 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], '" />', $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="titlebg" 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], '" /></a>
</td>
<td class="windowbg2" valign="middle">
<form action="', $scripturl, '?action=login2" method="post" accept-charset="', $context['character_set'], '" 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>
</div>';
}
?>
// List all users online today
echo '
', $txt[3000], ':<br />', implode(', ', $context['list_users_online_today']);
<?php
// Version: 1.1.3; BoardIndex
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="0" cellspacing="0">';
if ($modSettings['enableShoutBox'])
echo' <tr>
<td>
<script language="JavaScript" type="text/javascript">
var sb_current_header = false;
function ajax_shoutBox_collapse(mode)
{
document.getElementById("ajax_shoutbox_collapse").src = smf_images_url + (mode ? "/expand.gif" : "/collapse.gif");
document.getElementById("ShoutBox").style.display = mode ? "none" : "";
sb_current_header = mode;
}
</script>
' . getShoutBoxContent() . '
</td>
</tr>';
echo' <tr>
<td valign="bottom">', theme_linktree(), '</td>
<td align="right">';
if (!$settings['show_sp1_info'])
echo '
', $txt[19], ': ', $context['common_stats']['total_members'], ' &#8226; ', $txt[95], ': ', $context['common_stats']['total_posts'], ' &#8226; ', $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="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"><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.png" 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.png" alt="', $txt[334], '" title="', $txt[334], '" border="0" />';
echo '</a></td>
<td>
<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="small2text windowbg2" valign="middle" width="4%" align="center">
', $board['posts'], '</td><td class="smalltext" valign="middle" width="4%" align="center">
', $board['topics'],'</td><td class="smalltext" valign="middle" width="22%">';
if (!empty($board['last_post']['id']))
echo '
<a href="', $board['last_post']['href'], '"><img alt="go" src="', $settings['images_url'], '/icons/last_post.gif" align="right" hspace="3" border="0" /></a>
', $board['last_post']['time'], '
', $txt['smf88'], ' <b>', $board['last_post']['link'], '</b> ', $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="catbg">
<td align="', !$context['right_to_left'] ? 'left' : 'right', '" class="smalltext">
<img src="' . $settings['images_url'] . '/new_some.png" alt="" border="0" align="middle" /> ', $txt[333], '
<img src="' . $settings['images_url'] . '/new_none.png" 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'] && !empty($context['categories']))
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>
<td class="blocktitle" align="center" colspan="2"><b>', $txt[685], '</b></td>
</tr>';
// This is the "Recent Posts" bar.
if (!empty($settings['number_recent_posts']))
{
echo '
<tr>
<td class="titlebg" 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], ' "', $context['latest_post']['link'], '" ', $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="titlebg" 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="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>';
}
// Show a member bar. Not heavily ornate, but functional at least.
if ($settings['show_member_bar'])
{
echo '
<tr>
<td class="titlebg" 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="titlebg" 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] . ': "' . $context['latest_post']['link'] . '" (' . $context['latest_post']['time'] . ')<br />' : '', '
<a href="', $scripturl, '?action=recent">', $txt[234], '</a>
</td>
<td width="32%" class="smalltext" valign="top">
', $txt[2003], ' ', $context['common_stats']['total_members'],$txt[2004],' <a href="', $scripturl, '?action=register">',$txt[2005],' ',$context['common_stats']['total_members1'],$txt[2006],'</a><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>
// List all users online today
echo '
', $txt[140], ':<br />', implode(', ', $context['list_users_online_today']);</tr>';
}
// "Users online" - in order of activity.
echo '
<tr>
<td class="titlebg" 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']);
// users in chat
if (isset($context['chat_links'])){
if (count($context['chat_links']) == 0 )
echo '<br />' . $txt['chat_no_user'];
elseif (count($context['chat_links']) == 1 )
echo '<br /> 1' . $txt['chat_aUser']. ':<br />', implode($context['chat_links']);
else
echo '<br /> ' . count($context['chat_links']). $txt['chat_users']. ':<br />', implode(', ', $context['chat_links']);
}
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="titlebg" 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="titlebg" 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" accept-charset="', $context['character_set'], '" 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>';
}
function getShoutBoxContent()
{
global $scripturl;
// Get the URL to the chat directory:
if (!defined('AJAX_CHAT_URL'))
{
define('AJAX_CHAT_URL', str_replace("index.php", "chat/", $scripturl));
}
// Get the real path to the chat directory:
if (!defined('AJAX_CHAT_PATH'))
{
define('AJAX_CHAT_PATH', dirname(__FILE__) . '/../chat/');
}
// Validate the path to the chat:
if (@is_file(AJAX_CHAT_PATH . 'lib/classes.php'))
{
// Include Class libraries:
require_once(AJAX_CHAT_PATH.'lib/classes.php');
// Initialize the shoutbox:
$ajaxChat = new CustomAJAXChatShoutBox();
// Parse and return the shoutbox template content:
return $ajaxChat->getShoutBoxContent();
}
return null;
}
?>
Quote from: JimM on March 10, 2009, 12:04:44 AM
@digger1874 - that line is not in your /Themes/customtheme/BoardIndex.template.php. That line is in the /Sources/BoardIndex.php file.
Quote', $txt['most_online_ever'], ': ', $modSettings['mostOnline'], ' (' , timeformat($modSettings['mostDate']), ')
</span>
</td>
</tr>'
Quote from: JimM on March 10, 2009, 12:04:44 AM
@digger1874 - that line is not in your /Themes/customtheme/BoardIndex.template.php. That line is in the /Sources/BoardIndex.php file.
Quote from: mcrat on October 14, 2008, 04:32:26 AMQuote from: Frozt on October 02, 2008, 07:21:07 AM
I install the version 1.4.0 in smf 1.1.6 but after logoff I can´t see the list of users in "Users Logged In Today", I see only the number of users logged today:
Total: xx (Visible: xx, Hidden: xx)
but not the list of name of that users
I search in all the admin settings and I can´t find an option for allow see the users logged today for visitors, I dont know if there are this option or if visitors cant see the list of users. When I login I can see the list of users logged today.
Is there an option for active it to see the list the visitors too?
In the Users Online module I can see the users logged if I loged or not
I have the default theme in the forum
I've got this problem as well, (1.4.0 using 1.1.6 SMF) except using modified default theme.
Is this mod supposed to show the amount of members logged in today, as well as their names? Or have I got it confused and it is only supposed to show the number of people logging in that day?
At the moment, like Frozt, I only see
Total: xx (Visible: xx, Hidden: xx)
but not the list of users who have logged in.
I manually copy/pasted the code in, so is there a specific section that I could have messed up? Any help would be great.
Quote from: Buwan on April 18, 2009, 06:46:12 PMQuote from: mcrat on October 14, 2008, 04:32:26 AMQuote from: Frozt on October 02, 2008, 07:21:07 AM
I install the version 1.4.0 in smf 1.1.6 but after logoff I can´t see the list of users in "Users Logged In Today", I see only the number of users logged today:
Total: xx (Visible: xx, Hidden: xx)
but not the list of name of that users
I search in all the admin settings and I can´t find an option for allow see the users logged today for visitors, I dont know if there are this option or if visitors cant see the list of users. When I login I can see the list of users logged today.
Is there an option for active it to see the list the visitors too?
In the Users Online module I can see the users logged if I loged or not
I have the default theme in the forum
I've got this problem as well, (1.4.0 using 1.1.6 SMF) except using modified default theme.
Is this mod supposed to show the amount of members logged in today, as well as their names? Or have I got it confused and it is only supposed to show the number of people logging in that day?
At the moment, like Frozt, I only see
Total: xx (Visible: xx, Hidden: xx)
but not the list of users who have logged in.
I manually copy/pasted the code in, so is there a specific section that I could have messed up? Any help would be great.
I have the opposite issue. I see the users names fine, but for the stats above the names, what I see is:
: 4 (: 4, : 0)
I have smf 1.1.8, and installed ver. 1.4.0 of this mod. The install was fine with no errors. I looked at the parser and checked the edits that were done, and they appear to be correct. I'm not a coder, so if anyone can help, please use short sentences and small words. Pictures would be a plus! :D
Quote from: JimM on April 22, 2009, 11:57:32 AM
@Buwan - you may be missing some language strings. What language is the default on your forum?
Quote from: Buwan on April 23, 2009, 06:17:42 AMQuote from: JimM on April 22, 2009, 11:57:32 AM
@Buwan - you may be missing some language strings. What language is the default on your forum?
English.
Quote from: JimM on April 25, 2009, 08:33:26 PM
Attach your /Themes/yourtheme/BoardIndex.template.php to you next post and I will take a look. What theme are you using?
$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';
Quote from: JimM on April 25, 2009, 10:49:43 PM
That file is ok, Nothing wrong with it that I can see. Check your /Themes/default/languages/Modifications.english.php and make sure this is in there:Code Select$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';
$txt['topic-start'] = 'Topic Start';
$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';
Quote from: JimM on April 25, 2009, 11:06:43 PM
Please provide a screenshot of the bottom of your forum so I can see exactly what you are seeing. There is no reason this should not work on the default theme.
Quote from: JimM on April 25, 2009, 11:52:54 PM
Is this what a logged in user sees? Check that the default language of the forum and the language in the logged user's profile are the same. Both should be English if that is your forum default.
What does a guest see?
Quote from: JimM on April 26, 2009, 01:39:32 AM
Uninstall the mod, download another copy from the mod site and apply it again through the package manager. Verify that all the edits were accomplished.
$context += getMembersOnlineStats($membersOnlineOptions);
Quote from: JimM on April 26, 2009, 10:16:26 PM
Copy the Stats.english.php and the Modifications.english.php to Stats.english-utf8.php and Modifications.english-utf8.php and you should be good to go.
Quote from: V@POR on May 24, 2009, 02:39:39 PM
Is this compatible with 1.1.9 yet ? Thanks
Quote from: JimM on May 06, 2009, 10:30:34 PM
Looks like you added part of the code twice in your custom theme. Remove the duplicate and you should be all set.
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'], ')';
echo $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
// if (!$context['user']['is_guest']) - commented out
echo ' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_hidden_users_online_today']), ', ', $txt['uot_hidden'], ': ', $context['num_hidden_users_online_today'], ')';
if (!empty($context['users_online_today']) && !$context['user']['is_guest'])
if (!empty($context['users_online_today']))
$context['num_users_online'] = count($context['users_online']) + $context['num_users_hidden'];
Quote from: CL0WNER on May 27, 2009, 10:30:22 PM
anybody know why i cant find this line?Code Select$context['num_users_online'] = count($context['users_online']) + $context['num_users_hidden'];
in BoardIndex.template.php
Quote from: Hell Raiser on May 29, 2009, 06:48:54 AM
I think there is something wrong i can also cant find that line :'(
Quote from: usa4all on May 23, 2009, 06:42:49 AM
Help wanted..
I try to install this mod. But i getting this error message: ./Themes/default/languages/Stats.english.php test failed.
The default language of the forum is dutch. Is that a problem?
Any tips how to get this mod working? I'm using the them safmc..
tx in advance
Quote from: usa4all on May 23, 2009, 06:42:49 AM
Help wanted..
I try to install this mod. But i getting this error message: ./Themes/default/languages/Stats.english.php test failed.
The default language of the forum is dutch. Is that a problem?
Any tips how to get this mod working? I'm using the them safmc..
tx in advance
Quotebut it says
: 11 (: 11, : 0)
Quote from: philcross on May 31, 2009, 07:43:41 AMWell I got almost every language so I don't know which versions those are and won't upgrade all those language that are too muchQuotebut it says
: 11 (: 11, : 0)
Have you recently installed a new language pack?
I had that happen with a different Mod when I installed the English British pack instead of English US - the words just vanished and left the same stuff as you have got.
QuoteI am running Users Online Today v 1.5.4 on 2.0 RC1
It shows my most users online was May 20th.
However, I had more users than that online yesterday but the info isnt reflecting this.
Anyone have a solution or suggestion please?
Thanks
Quote from: JimM on May 31, 2009, 01:29:07 AMThanks, works great.
The code was not in that file. I added it, but you need to use the mod parser and make sure all the other edits took otherwise it still won't work.
Try this one.
Quote from: JimM on June 01, 2009, 10:25:14 AMI have no idea what you mean... I have a very basic understanding of this stuff, but I have got everything right except this last thing.
@Bachian - Make sure the edits for ./Themes/default/languages/Modifications.english.php are in place.
Quote from: Bachian on June 01, 2009, 10:33:03 AMQuote from: JimM on June 01, 2009, 10:25:14 AMI have no idea what you mean... I have a very basic understanding of this stuff, but I have got everything right except this last thing.
@Bachian - Make sure the edits for ./Themes/default/languages/Modifications.english.php are in place.
Can you explain this for me, please?
Quote from: JimM on June 01, 2009, 10:36:54 AMNo, and I have no idea how to do that.Quote from: Bachian on June 01, 2009, 10:33:03 AMQuote from: JimM on June 01, 2009, 10:25:14 AMI have no idea what you mean... I have a very basic understanding of this stuff, but I have got everything right except this last thing.
@Bachian - Make sure the edits for ./Themes/default/languages/Modifications.english.php are in place.
Can you explain this for me, please?
Did you install the mod through the package manager? The file you uploaded didn't have the mod code in it. There are some more files that need to be edited for the mod to work completely. Did you edit those files manually?
Quote from: JimM on June 01, 2009, 10:45:40 AMI edited it and now it works. :D
Here is some documentation on using the package manager.
Package Manager (http://docs.simplemachines.org/index.php?board=49.0;sort=subject)
Quote from: JimM on June 22, 2009, 01:46:25 PM
@ Joe N - The edits to /Sources/BoardIndex.php are already there in that file.
Quote from: usa4all on July 06, 2009, 05:33:19 PM
By Installing on my 1.1.9 forum i get this faillure : 6. Voer aanpassing uit ./Themes/default/languages/Stats.english.php Test mislukt (Failed)
How can i solve this? Seems like i don't get this mod installed.
See the attached jpg file , thats'what i see at the infocenter. ( Only a number )
Any help appreciated
Quote from: Sharp.Shot on July 18, 2009, 12:43:57 AM
aw06
There is no way to do this because guests cannot log in to the forum. ;)
Quote from: JimM on July 17, 2009, 11:54:28 PMHow it make? Give me a code please. ???
Make sure you add the language strings in your Modifications.yourlanguage.php file. This mod only supports English.
Quotewell, tru, but they are still logged via IP .. so it should be able to count logged IP's
Type Action Description
1. Execute Modification ./Sources/BoardIndex.php Test failed
2. Execute Modification ./Themes/default/BoardIndex.template.php Test failed
3. Extract File ./Sources/Subs-MembersOnlineToday.php
4. Extract File ./Themes/default/languages/MembersOnlineToday.english.php
Quote from: Labradoodle-360 on July 21, 2009, 11:59:06 PM
I am running SMF Version 1.1.10 and I installed this mod to my default theme without problems.
It did not show up in the info center, so I manually entered the step that was catching.
Now I can see the section where it SHOULD say "Users Online Today" and then a big empty box where it SHOULD list them.
No "Users Online Today" header and no users loading in the box...help appreciated
Quote from: JimM on July 18, 2009, 11:56:41 PMI add strings only into Modifications.russian-utf8.php and it all works now. ;D Big thanks
@aPTyPuK - You will need to translate the language strings into you forum language. There are two files /Themes/default/languages/Stats.english.php and /Themes.default/languages/Modifications.english.php. Once you have translated the strings, you would save the file as Stats.yourlanguage.php and Modifications.yourlanguage.php.
mg.online_color, mg.id_group, mg.group_name
mg.online_color, mg.id_group, mg.group_name, mem.gender
Some basic color coding...
if (!empty($row['online_color']))
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['id_member'] . '"' . $title . ' style="color: ' . $row['online_color'] . ';">' . $row['real_name'] . '</a>';
else
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['id_member'] . '"' . $title . '>' . $row['real_name'] . '</a>';
if(!empty($row['gender']) && !empty($modSettings['enable_gender_member_color']))
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['id_member'] . '" style="color: #' . ($row['gender'] == 1 ? $modSettings['male_color'] : $modSettings['female_color']) . ';">' . $row['real_name'] . '</a>';
else {
if (!empty($row['online_color']))
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['id_member'] . '"' . $title . ' style="color: ' . $row['online_color'] . ';">' . $row['real_name'] . '</a>';
else
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['id_member'] . '"' . $title . '>' . $row['real_name'] . '</a>';
}
Quote from: FightToTheDeath on September 05, 2009, 01:15:30 PM
How can i add this mod in mystic multi v2 theme? Please help.
Quote from: TheListener on September 05, 2009, 01:50:58 PMQuote from: FightToTheDeath on September 05, 2009, 01:15:30 PM
How can i add this mod in mystic multi v2 theme? Please help.
Have you tried a manual install?
Which smf version?
Quote from: PiWi on September 07, 2009, 08:21:02 AM
I can't find the first string: $context += getMembersOnlineStats($membersOnlineOptions);
In sources boardindex.php
????
Gr Patrick
Quote from: JimM on September 07, 2009, 06:24:34 PM
@PiWi - Try this one and let me know if it works.
Quote from: JimM on September 07, 2009, 06:24:34 PM
@PiWi - Try this one and let me know if it works.
Quote from: Sabre™ on September 08, 2009, 05:28:58 PM
You can remove the second occurrence of $txt['uot_users_online_today'], but that is purely a guess ;)
If you like, you may post your BoardIndex.template and I'll have a look for you while Im on.
Quote from: Sabre™ on September 08, 2009, 05:16:26 PM
@ Gav-Aus & PiWi
Try the attached files with your name on it.
Let me know if they work ok for you.
Gav- Aus, I left your edits in there so you can see where you went wrong. I have only canceled them out.
Good attempt though :)
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '<br />[' . implode('] [', $context['membergroups']) . ']';
Quote from: w1z8it on September 08, 2009, 06:08:21 PM
It's the group keys that I only want 1 occurrance of each, preferbly I'd like to remove the dupes that's listed in the Users Logged In Today list ;)
Quote from: Sabre™ on September 08, 2009, 05:16:26 PM
@ Gav-Aus & PiWi
Try the attached files with your name on it.
Let me know if they work ok for you.
<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
Quote from: Sabre™ on September 09, 2009, 06:41:31 AMQuote from: w1z8it on September 08, 2009, 06:08:21 PM
It's the group keys that I only want 1 occurrance of each, preferbly I'd like to remove the dupes that's listed in the Users Logged In Today list ;)
Oh sorry champ, I misread your question lol
Jims directions should work for you.
@ Gav-Aus
Try the attached template.
Quote from: Sabre™ on September 09, 2009, 06:07:06 PM
Find this lineCode Select<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
and try changing titlebg to catbg. Im pretty sure thats all it takes.
See if it works.
Quote from: JimM on September 08, 2009, 10:17:57 PM
@w1z8it - In the code that you added to your BoardIndex.template.phpCode (Find & Delete) Select// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '<br />[' . implode('] [', $context['membergroups']) . ']';
This code occurs twice. Delete the 2nd occurrence of it.
Quote from: JimM on September 10, 2009, 09:19:26 PM
@w1z8it - after you install the mod, there will be 2 occurrences of that code. Install the mod as normal and then delete the second one. Prior to installing the mod, there will only be one. The file you posted did not have the mod installed.
Quote from: JimM on September 10, 2009, 09:19:26 PM
@w1z8it - after you install the mod, there will be 2 occurrences of that code. Install the mod as normal and then delete the second one. Prior to installing the mod, there will only be one. The file you posted did not have the mod installed.
Quote from: w1z8it on September 11, 2009, 09:56:47 AM
Ummm I have had the mod installed since day one.
Quote from: Sabre™ on September 11, 2009, 04:05:22 PMQuote from: w1z8it on September 11, 2009, 09:56:47 AM
Ummm I have had the mod installed since day one.
What Jim has stated is correct.
You may have had the mod installed when you posted your template [HERE] (http://www.simplemachines.org/community/index.php?topic=55513.msg2250134#msg2250134) buddy, but as you can see it is the backup of your boardindex.template, notice the ~ , that means it is the backup and is probably from before the mod was installed.
Looking at that template myself, there would be two occurrences of the code, although they slightly differ, which is why you'd find only one occurrence.
Try searching for show_group_key and you should find the other.
NBK*Twitch , can you show me a screen shot of what you're seeing plz?
<div class="windowbg">
<p class="section">
<img src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['uot_users_online_today'], '" />
</p>
Quote from: Sabre™ on September 11, 2009, 07:08:58 PMI can't seem to find that :( .
Cool.
You can remove thisCode Select<div class="windowbg">
<p class="section">
<img src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['uot_users_online_today'], '" />
</p>
and a </div> at the end of this mods code.
That is for the layout as you have it now.
I've also attached your template from the previous post and have changed the code a little to have what I think is a better layout.
Try it if you like, or suggest a change etc etc :)
Quote from: Sabre™ on September 12, 2009, 12:34:08 AMNah it looks great now :D.
lol cool.
If you'd like any change to it, just mention where and what, and I'll see what I can do.
I only quickly brushed through your template, so there may be little changes you'd like.
If not, then enjoy buddy :)
Undefined index: uot_users_online_today
File: /home/xxxxxx/public_html/forum/Themes/default/BoardIndex.template.php (main sub template - eval?)
Line: 418
Undefined index: uot_users_online_today
File: /home/xxxxx/public_html/forum/Themes/default/BoardIndex.template.php (main sub template - eval?)
Line: 415
Quote from: Sabre™ on September 15, 2009, 08:53:49 AM
Hi frankybv,
Did you upload somebody else's template?
It may cause errors to your site if you do not have the same modifications installed, and other possible errors regarding theme images etc..
Check your error log in your maintenance section of your Admin panel, and see if any are there.
I would be more than happy to edit your themes template if you like, I believe that would be best for you buddy.
But if you're happy with it, then I'm glad I could have helped :)
Quote from: dkharp on September 30, 2009, 01:13:05 AM
Hello,
I am running smf 1.1.10 I seem to can not find the right line in - sources / board index.php to add the right code for this mod.
Can anyone help?
Quote from: aw06 on September 30, 2009, 01:42:14 AMQuote from: dkharp on September 30, 2009, 01:13:05 AM
Hello,
I am running smf 1.1.10 I seem to can not find the right line in - sources / board index.php to add the right code for this mod.
Can anyone help?
You Parsed the version for SMF 2.0 [1.5.4] ... Select version 1.4.0 and parse for SMF 1.1.10 :)
Quote from: dkharp on September 30, 2009, 03:24:45 AM
I'm an idiot.
But the manual install is wrong..I think
One more thing how do I get it to show in a TP block? Or no..
Thanks folks for your help!
Quote from: Rhyme on September 30, 2009, 01:48:11 AMQuote from: aw06 on September 30, 2009, 01:42:14 AMQuote from: dkharp on September 30, 2009, 01:13:05 AM
Hello,
I am running smf 1.1.10 I seem to can not find the right line in - sources / board index.php to add the right code for this mod.
Can anyone help?
You Parsed the version for SMF 2.0 [1.5.4] ... Select version 1.4.0 and parse for SMF 1.1.10 :)
Wow what a simple fix right there XD. You know I've been trying to figure that out a few times and it was just so simple. I was on the wrong one LOL. I know this wasn't my question, but thanks for the help XD
Quote from: aw06 on September 30, 2009, 10:59:46 AMQuote from: Rhyme on September 30, 2009, 01:48:11 AMQuote from: aw06 on September 30, 2009, 01:42:14 AMQuote from: dkharp on September 30, 2009, 01:13:05 AM
Hello,
I am running smf 1.1.10 I seem to can not find the right line in - sources / board index.php to add the right code for this mod.
Can anyone help?
You Parsed the version for SMF 2.0 [1.5.4] ... Select version 1.4.0 and parse for SMF 1.1.10 :)
Wow what a simple fix right there XD. You know I've been trying to figure that out a few times and it was just so simple. I was on the wrong one LOL. I know this wasn't my question, but thanks for the help XD
XD ?? :o
Quote from: VegaTheChosen on October 07, 2009, 12:42:47 AM
hi everyone did a search in this thread didnt find a solution, I installed this and it worked fine, made edits on my custom theme but user names of who visited is not showing heres an example along with my board index from my theme, thanks for the help
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi35.tinypic.com%2Faxmjkj.jpg&hash=880d570fe3662b8f91aa84e18460c13eb6d1bfe3)
Quote from: Kat9119 on October 15, 2009, 04:09:21 PM
Any way to make this one show users within the last 24hrs, with member names to all users, including guests? Or is there some other edit/script to use?
......is there a way to make it appear UNDER everything else in that user info panel (above login for guests)?
Quote from: from the mod authorAdds a list of all users that were online on the current day to the 'Info Center'.
// Who's been online today - very basic version 1.0
// the database table smf_members contains the last login unix time stamp for each member as well as the member name
function ssi_whosOnlineToday($output_method = 'echo'){
$begining_today_time = strtotime(date('Y-n-j')); //get unix time at beginning of today
$result = db_query("
SELECT memberName
FROM {$db_prefix}members
WHERE lastLogin > $begining_today_time
ORDER BY memberName ASC"); //find all members logged in since beginning of today
$mc=mysql_num_rows($result); //total members logged in today
while ($row = mysql_fetch_array($result)){ //print results, format as desired
echo $row['memberName'];
if($mc>1){echo ', ';}
$mc--;
}
}
Quote from: Powerbob on October 16, 2009, 07:41:41 AMThats good to know. Now if the other mods I love get updated to rc2 :D.
1.5.4 Works in RC2 as well 8)
Quote from: PiWi on September 10, 2009, 08:48:12 AMQuote from: Sabre™ on September 09, 2009, 06:07:06 PM
Find this lineCode Select<td class="titlebg" colspan="2">', $txt['uot_users_online_today'], '</td>
and try changing titlebg to catbg. Im pretty sure thats all it takes.
See if it works.
YES it works! thanx a lot Sabre! I could never think of this at my own!
Gr Patrick
Quote from: Sabre™ on October 25, 2009, 11:50:10 PM
I have to admit, I was racking my brain trying to figure out what you meant by "quests".
I couldn't figure out if you wanted to display how many quests they'd ventured/completed in a game, or their 'actions' within the forum.
Then after reading another thread, it dawned on me that this may be a typo, and you could've meant "guests" lol
Yep, sometimes the simplest of things get by me :P
So this would require the name "Guests" to appear once, and the number visited that day displayed next to it?
At this time, I have no idea how to display this, as I've never looked into it, and the mod author is on hiatus, so there is no telling when you could receive assistance for this.
Opening your own thread may be fruitful for you, as someone of more experience may have the solution for you.
Good luck buddy :)
Quote from: baulknaub on November 10, 2009, 09:32:03 PM
Well, I am scratching my head - I just upgraded to 2.0 RC2 and my templete's admin section no longer works, which is a topic for another thread of course. But mu Users Online no longer appears at the bottom. I have uninstalled and reinstalled it and can see the changes in my files as outlined on the mod page and have verified the 2 additional files are in their proper place. In other words - all looks like it is should be but it just doesn't show up.
So - any suggestion of what I could check next would be helpful.
Quote from: JimM on November 04, 2009, 08:40:08 AM
This mod already installs fine on 2.0RC2.
Quote from: imrich on November 12, 2009, 09:23:04 AMQuote from: JimM on November 04, 2009, 08:40:08 AM
This mod already installs fine on 2.0RC2.
Yes it seems to work, but I did notice this in my log when I installed it:
http://www.domain.tld/forum/index.php?action=admin;area=packages;sa=install2;package=Users_Online_Today_1.5.4.zip;pid=08: Undefined index: theme
File: /user/domain/public_html/forum/Sources/Packages.php
Line: 935
I'm not sure if this is a bug in SMF 2 RC2 or if it's an issue with this mod?
During install I did choose to install it in a couple of optional themes that I have, but I'm mostly using curve for now.
The mod does seem to be working ok.
Quote from: imrich on November 14, 2009, 08:44:42 AM
Thanks for this mod. I wish the mod would allow changing it's settings via the modifications settings admin page.
Quote from: imrich on November 17, 2009, 08:04:32 AM
There is a minor display bug in this mod when the period is set to 'last_7_days'.
With the period set to 'last_7_days', then when you hover your mouse over the list of members that have been online within the last 7 days, members that are over 24 hours old display the date last logged in as 'Yesterday AT xx:xx PM', but when you view their profile, you can see that they were last active several days earlier (but the time of day is correct). So it seems that the 'yesterday' logic is not correct when the user was last logged in longer than 24 hours.
Quote from: imrich on November 17, 2009, 08:04:32 AM
There is a minor display bug in this mod when the period is set to 'last_7_days'.
With the period set to 'last_7_days', then when you hover your mouse over the list of members that have been online within the last 7 days, members that are over 24 hours old display the date last logged in as 'Yesterday AT xx:xx PM', but when you view their profile, you can see that they were last active several days earlier (but the time of day is correct). So it seems that the 'yesterday' logic is not correct when the user was last logged in longer than 24 hours.
$last_login_txt = $yesterday . strftime($time_fmt, forum_time(true, $row['last_login']));
$last_login_txt = strip_tags(timeformat($row['last_login']));
Quote from: qubbah on January 25, 2010, 02:45:54 AManybody can help?
how can we make hidden users completely remove from the list. Some of membergroup can see the hidden users. I want it completely hide the hidden users. tq
or completely remove admin login today in list?
Quote from: Sabre™ on January 29, 2010, 06:24:42 AM
Did you manually install the mod, or use the package parser in your admin panel?
The code was added twice to your template, but shouldn't have interfered with each other, rather it would have displayed the feature twice.
It seems that you may have to check all of the files this mod alters, and remove any duplicate code, aswell as double check that they are there.
Attached is your template.
$context += getMembersOnlineStats($membersOnlineOptions);
Quote from: Filipina on February 18, 2010, 03:49:42 PM
I want Users Online Today to show for guests on the forum main. I am assuming this is a permissions issue but I cannot find the setting.
$txt['uot_users_online_today']='Users Logged In Today';
Quote from: Sabre™ on February 24, 2010, 05:15:07 AM
Go to your Modifications.english.php template (default/languages/Modifications.english.php) and look at the bottom of the page for this textCode Select$txt['uot_users_online_today']='Users Logged In Today';
Just above it, you will see this ?> move it to the bottom of the page, and that should remove the text from the top of your forum. :)
Quote from: IvoLeite on February 25, 2010, 11:43:34 AM
Is there a way to put the number os guests that have visited to forum today in the same place as this mod?
$txt['uot_users_online_today'] = 'Les utilisateurs connectés Aujourd\'hui';
$txt['uot_total'] = 'Total';
$txt['uot_visible'] = 'Visible';
$txt['uot_hidden'] = 'Caché';
Quote from: fairytears on March 11, 2010, 10:07:51 PM
Hello
Great mod :)
I am using smf 1.1.11 and I was wondering if there is any way to show the total members yesterday besides the users online today.
Thank you :)
Quote from: Carceri on February 19, 2010, 08:17:42 AMI can't find the readme in the 1.4.0 download. I would like to be able to do the same thing as Filipina, but I use SMF 1.1.11, so I cannot use 1.5.x. Could you post the instructions on what to change to make the online today list show users for guests as well?Quote from: Filipina on February 18, 2010, 03:49:42 PM
I want Users Online Today to show for guests on the forum main. I am assuming this is a permissions issue but I cannot find the setting.
Take a look at the readme.txt file included with the mod.
Quote from: DJ Omnimaga on March 13, 2010, 04:13:37 AMQuote from: Carceri on February 19, 2010, 08:17:42 AMI can't find the readme in the 1.4.0 download. I would like to be able to do the same thing as Filipina, but I use SMF 1.1.11, so I cannot use 1.5.x. Could you post the instructions on what to change to make the online today list show users for guests as well?Quote from: Filipina on February 18, 2010, 03:49:42 PM
I want Users Online Today to show for guests on the forum main. I am assuming this is a permissions issue but I cannot find the setting.
Take a look at the readme.txt file included with the mod.
Thank you for using the Users Online Today Modification,
This modification allows users to see who logged in during the day.
It is possible to chance a few options for by editing the BoardIndex.php
file. The default options found there, are the following:
$membersOnlineTodayOptions = array(
'sort' => 'login_time',
'reverse_sort' => true,
'period' => 'current_day',
'canview' => 'registered',
);
The following options are possible:
Option: sort
Possible Values: 'login_time', 'member_name'
Description: Sort the user list by either login time or their username
Option: reverse_sort
Possible Values: true, false
Description: Sort the user list in ordinary or reverse order
Option: period
Possible Values: 'current_day', 'last_24_hours', 'last_7_days'
Description: The period the user list covers
Option: canview
Possible Values: 'admin', 'registered', 'everyone'
Description: Determines who can view the user list
Quote from: JimM on May 27, 2009, 03:32:45 PM
Where was my head yesterday? Also change this line:Code Selectif (!empty($context['users_online_today']) && !$context['user']['is_guest'])
To this:Code Selectif (!empty($context['users_online_today']))
Try that.
Quote from: hcfwesker on March 22, 2010, 01:16:04 AM
Should be under your ...../Themes/Your Theme/Board.Index.Template.php file.
Quote from: Carceri on April 06, 2010, 08:41:48 AM
I guess at some point I forgot to update the text when I uploaded a new version.
['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_today'], ')';
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_today'], ')';
Quote from: Info~ on April 07, 2010, 07:50:03 AM
BroadIndex.template attached...
$context += getMembersOnlineStats($membersOnlineOptions);
QuoteInstalling this package will perform the following actions:
Type Action Description
1. Execute Modification ./Sources/BoardIndex.php Test failed
2. Execute Modification ./Themes/default/BoardIndex.template.php Test failed
3. Extract File ./Sources/Subs-MembersOnlineToday.php
4. Extract File ./Themes/default/languages/MembersOnlineToday.english.php
Quote from: MarkoKg on April 12, 2010, 08:24:23 AM
Hello there.
I try to install this mod on smf 1.1.11 version, but i cant find this code in BoardIndex.php:Code Select$context += getMembersOnlineStats($membersOnlineOptions);
Can you please help me with this?
Attached is my BoardIndex.php from Sources directory.
Quote from: Info~ on April 07, 2010, 07:50:03 AM
I managed to install it successfully, but there is something I would like to change...
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fimg146.imageshack.us%2Fimg146%2F3498%2F75686406.jpg&hash=c24bd716295034d57d906cd900381bd77d8d46be)
As you can see it's different than "Users Online" box, how can I make it so it will be same as "Users online", so to move "online.gif" down, and to make that black lines., also to move text to right...
SMF Forum version: 2.0 RC2
BroadIndex.template attached...
Quote from: anshar on May 13, 2010, 07:59:59 AM
Instaled the latest mod version on clean SMF 2.0 RC3. No errors but the mod is not working, nothing new on the main forum page, basicaly no trace of users logged in today.... What went wrong?
// If they are logged in, but SP1 style information is off... show a personal message bar.
// If they are logged in, but SP1 style information is off... show a personal message bar.
// Users online today
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>';
Quote from: Intrepid on August 06, 2010, 08:59:01 PM
Yes i checked it so i dont need to make those file operations?
PS.: I forgot to say the mod didnt worked because i use custom template so i alredy changed the template file so its work except i dont see the total,visible,hidden text
Quote from: xenovanis on August 06, 2010, 09:01:21 PMQuote from: Intrepid on August 06, 2010, 08:59:01 PM
Yes i checked it so i dont need to make those file operations?
PS.: I forgot to say the mod didnt worked because i use custom template so i alredy changed the template file so its work except i dont see the total,visible,hidden text
Oooooooh :P
No, then there is no need to make the file operations, again. What is your forumlanguage?
Quote from: xenovanis on August 06, 2010, 09:04:02 PM
Default english or utf8?
Quote from: xenovanis on August 06, 2010, 09:09:13 PM
In the /Themes/default/languages/ folder, find this file
MembersOnlineToday.english.php
make a copy of it and rename that copy MembersOnlineToday.english-utf8.php.
?>
// Users online today
$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';
$txt['users_online_today'] = 'Online Today';
$txt['num_hits'] = 'Total page views';
$txt['average_hits'] = 'Average page views per day';
$txt['users_online_today'] = 'Most Online Today';
$txt['num_hits'] = 'Total page views';
$txt['average_hits'] = 'Average page views per day';
Quote from: smithtr on August 29, 2010, 10:47:23 PM
I notice mod, doesn't have code? what is that. I wonder MembersOnlineToday.english.php. tell me where is found? I am not sure where is find? who today online. I invesitage to search something?
P.S
ASAP
thank
Quote from: (F.L.A.M.E.R) on August 29, 2010, 10:49:01 PMQuote from: smithtr on August 29, 2010, 10:47:23 PM
I notice mod, doesn't have code? what is that. I wonder MembersOnlineToday.english.php. tell me where is found? I am not sure where is find? who today online. I invesitage to search something?
P.S
ASAP
thank
In there:
./Themes/default/languages
Quote from: smithtr on August 29, 2010, 10:51:36 PMQuote from: (F.L.A.M.E.R) on August 29, 2010, 10:49:01 PMQuote from: smithtr on August 29, 2010, 10:47:23 PM
I notice mod, doesn't have code? what is that. I wonder MembersOnlineToday.english.php. tell me where is found? I am not sure where is find? who today online. I invesitage to search something?
P.S
ASAP
thank
In there:
./Themes/default/languages
which on Admin Control? that is correct? I can try fix test on /themes/default/languages
Quote from: Sabre™ on August 30, 2010, 09:22:13 AM
First of all, you have an SMF2 site yes?
Did you install through the package manager in your admin panel, or manual install?
Did you install "Users_Online_Today_1.5.6.tar.gz" or the other?
Were there any errors when you installed the mod if through package manager?
Are there any errors in your "error log"?
Would you be willing to PM somebody and give them admin access to install it for you?
Quote from: PascalCX on November 14, 2010, 05:26:20 AM
RC 4.0 installed without errors
but:
Quote from: Phat^Trance on November 22, 2010, 03:20:35 PM
is there any settings for this plugin? cannot find anything at admin controll panel.
Quote from: Ken. on November 22, 2010, 07:23:52 PMQuote from: Phat^Trance on November 22, 2010, 03:20:35 PM
is there any settings for this plugin? cannot find anything at admin controll panel.
No settings in the CP, but if you look at the readme.txt file (in the zip) there are some edits that you can make to change the data that gets displayed.
// 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']);
// 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'])
QuoteYou can customise a few options. See the included readme.txt file for details (only 1.5.x versions)
// If they are logged in, but statistical information is off... show a personal message bar.
// Users Online Today
echo '
<h4 class="titlebg"><span class="left"></span>
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', '<span>', $txt['uot_users_online_today'], '</span>
</h4>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo
'<br />[' . implode('] [', $context['membergroups']) . ']';
}
echo '
</p>';
// Users Online Today
echo '
<h4 class="titlebg"><span class="left"></span>
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', '<span>', $txt['uot_users_online_today'], '</span>
</h4>
// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_today'], '</span>
</h4>
</div>
I am using Firefox not IE!
Quote from: Ciler on November 29, 2010, 10:18:04 AMAnd what theme you're using? I'm not a telepathist :)
Yes Bugo the mod is ok for the default theme...
// Users Online Today
echo '
<div class="infocenter_section">
<h4 class="titlebg">', $txt['uot_users_online_today'], '</h4>
<div class="windowbg">
<p class="section">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />
</p>
<div class="windowbg2 sectionbody">
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo
'<br />[' . implode('] [', $context['membergroups']) . ']';
}
echo '
</p></div></div></div>';
Quote5. Execute Modification ./Themes/default/languages/Modifications.english.php File not found
6. Execute Modification ./Themes/default/languages/Stats.english.php File not found
Quote from: bananiel on December 07, 2010, 12:53:57 PM
I'm trying to install this mod but it gives a error on installation :Quote5. Execute Modification ./Themes/default/languages/Modifications.english.php File not found
6. Execute Modification ./Themes/default/languages/Stats.english.php File not found
i installed the latest SMF + Simple Portal but it seems I'm missing 2 files.
can anybody tell me how to fix this ?
-Daniel-
Quote$context += getMembersOnlineStats($membersOnlineOptions)
Quote from: noaccess on March 10, 2011, 01:40:33 AM
I would like to make Users logged in today visible to guests. How do I go about doing this? Also, why on earth would this be disabled by default? It should be the other way around.
Quote from: Carceri on April 06, 2011, 09:20:22 AMNonsense of course, just like the other argument used a few pages before. Any random fellow can register on the forum and get more access (see more) than just a nickname. Anyway, it doesn't matter, I already changed it.Quote from: noaccess on March 10, 2011, 01:40:33 AM
I would like to make Users logged in today visible to guests. How do I go about doing this? Also, why on earth would this be disabled by default? It should be the other way around.
For privacy reasons. It could reveal that a user was registered on a specific forum, to a visitor who was not registered on the same forum. Basically this is keeping in line with the rest of SMF that a guest is by default not allowed to view the list of registered users.
Quote from: noaccess on April 07, 2011, 04:11:09 AMQuote from: Carceri on April 06, 2011, 09:20:22 AMNonsense of course, just like the other argument used a few pages before. Any random fellow can register on the forum and get more access (see more) than just a nickname. Anyway, it doesn't matter, I already changed it.Quote from: noaccess on March 10, 2011, 01:40:33 AM
I would like to make Users logged in today visible to guests. How do I go about doing this? Also, why on earth would this be disabled by default? It should be the other way around.
For privacy reasons. It could reveal that a user was registered on a specific forum, to a visitor who was not registered on the same forum. Basically this is keeping in line with the rest of SMF that a guest is by default not allowed to view the list of registered users.
The package manager currently allows only these file types: zip, tgz, tar.gz.
Quote from: booch_21 on April 09, 2011, 10:35:21 AM
Have been running 1.5.6 on RC5 just fine, but found this update today. Tried installing it and I get:Code SelectThe package manager currently allows only these file types: zip, tgz, tar.gz.
Have never had any luck installing this type of file. Any ideas? When I open and make the files into ZIP, it thinks the file is empty and won't install it. Thanks!
Quote from: Andrew94© on April 14, 2011, 02:38:33 PM
Use the zip file attached instead. I'm getting the same error, I guess the package manager doesn't like .tar.gz files. :o
Quote from: Andrew94© on April 14, 2011, 02:38:33 PM
Use the zip file attached instead. I'm getting the same error, I guess the package manager doesn't like .tar.gz files. :o
Quote from: sharks on April 23, 2011, 12:24:59 AM
I hope you release the final 1.6.0 version soon, then i can finally update this mod on my forums.
BTW, do you plan on fixing/adding anything to the mod for the SMF 1.1.x series? I haven't yet transitioned my main forums to 2.0 as i'm still tirelessly waiting for the gold release, but i'm just wondering if there's anything in the works.
Quote from: DJPlamen on April 24, 2011, 08:56:38 PM
Hi, first thanks for the great mod, I'm using it since RC2. Now I'm moving on RC5, so I installed, everything works fine (no conflict with 6 themes), but... Somehow the installer replaces the entire section of * Administration Center » * Modification Settings » * Miscellaneous...
Edit: I tried with the older version, works, but no admin settings... are they implemented in 1.6.0RC1?
Quote from: Carceri on April 25, 2011, 04:16:16 AMYes.. I also tried to uninstall both hacks that work with that Misc Tab, then install Users Oline, and then install them, but in that case thier settings do not appear. So, Users Online "locks" this settings tab :o :D
If you uninstall this mod, do the settings return?
$param1 = array_merge($param1, array(
array('select', 'uot_setting_sortby', 'label' => 'Users Online Today', array('username' => 'username', 'login_time' => 'login time'), 'preinput' => $txt['uot_setting_sortby_pre_txt'], 'postinput' => $txt['uot_setting_sortby_post_txt']),
array('select', 'uot_setting_sortorder', array('ascending' => 'ascending', 'descending' => 'descending'), 'preinput' => $txt['uot_setting_sortorder_pre_txt'], 'postinput' => $txt['uot_setting_sortorder_post_txt']),
array('select', 'uot_setting_period', array('current_day' => 'current day', 'last_24_hours' => 'last 24 hours', 'last_7_days' => 'last 7 days'), 'preinput' => $txt['uot_setting_period_pre_txt'], 'postinput' => $txt['uot_setting_period_post_txt']),
array('select', 'uot_setting_canview', array('admin' => 'administrators', 'registered' => 'registered users', 'everyone' => 'everyone'), 'preinput' => $txt['uot_setting_canview_pre_txt'], 'postinput' => $txt['uot_setting_canview_post_txt'])
));
Quote from: Arantor on April 25, 2011, 06:25:12 AM
No, it's not adding to the array, it's overriding its contents.
Quote from: Arantor on April 25, 2011, 06:25:12 AM
Not sure why you have the reloadSettings() call there either, should not be necessary IIRC.
Quote from: Arantor on April 25, 2011, 10:22:43 AM
That just implies they're being held in the cache, but that should be dealt with for you by SMF.
Quote from: BoZilla on April 26, 2011, 08:33:06 PM
This mod works great for an unmodded forum but does not show in the simpleportal mod block as does the Users Online mod 1.5.6.
Quote from: Carceri on April 27, 2011, 07:19:55 AMQuote from: BoZilla on April 26, 2011, 08:33:06 PM
This mod works great for an unmodded forum but does not show in the simpleportal mod block as does the Users Online mod 1.5.6.
I don't know anything about SimplePortal, but maybe their code is in some way incompatible with the way integration functions are used to install version 1.6.0 of this mod? Maybe they need to call the integration function integrate_pre_include somewhere in their code as SMF now does on every page?
Anyway, even though I try to make this do as few changes as possible to the SMF code, I don't test compatibility with other mods.
// 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>';
Quote from: enitram on April 29, 2011, 07:47:55 AM
Hallo,
I have SMF 1.13 and users online today 1.4.0 installed
I have some error messages in the forum error log, sins I went back to the default theme.
Reinstalled mod but still errors and it works but it does not show right at the bottom of the forum.
see image: http://i905.photobucket.com/albums/ac253/MartinePassion/UTR/Printscreens/usersonlinetoday.jpg
This are the errors:
"Apply Filter: Only show the errors with the same message
8: Undefined index: uot_visible
File: /home/unitedtu/public_html/Themes/default/BoardIndex.template.php
Line: 419"
also at line 417, 410 en 407, for uot_hidden, uot_total and uot_users_online_today.
I went to the mod board and went to see what files to change when installing manually.
I see a whole different code, I tried it but then it doesn't work at all.
Here is what is in my boardindex.template.php before lineCode Select// If they are logged in, but SP1 style information is off... show a personal message bar.
is installed automatically beginning at line 403Code Select// 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>';
Could you please help me out here?
Thanks.
Regards Martine
Quote from: enitram on May 04, 2011, 07:20:55 PM
Can someone help me please?
Quote, SMF should fall back to using the english ones if available.
Quotebut maybe not possible as Once Upon A Star is saying.
Quote from: tank_fv101 on May 16, 2011, 06:50:15 AM
I have this MOD installed on my forum (SMF 1.1.13), and it always works fine, except for one thing. The total of users it shows as online today is different to what is displayed on the original information panel is always less. For example:- UOT shows 40, and the original info panel show Most Online Today: 27.
$txt['uot_users_online_today']='Utilizadores online hoje';
$txt['uot_total']='Total';
$txt['uot_visible']='Visível';
$txt['uot_hidden']='Escondido';
$txt['uot_setting_sortby_pre_txt']='Ordenar a lista por utilizador';
$txt['uot_setting_sortby_post_txt']='';
$txt['uot_setting_sortorder_pre_txt']='Ordenar lista do utilizador online hoje';
$txt['uot_setting_sortorder_post_txt']='Ordenar';
$txt['uot_setting_period_pre_txt']='A lista de utilizadores deve cobrir os';
$txt['uot_setting_period_post_txt']='';
$txt['uot_setting_canview_pre_txt']='Fazer a lista de utilizadores visíveis';
$txt['uot_setting_canview_post_txt']=''
Quote from: easyrider77 on May 30, 2011, 01:42:36 PM
When users logged in is more then 650 about, no one cant see the forum index. And when i unistall this mod the forum index works perfect. Have you idea what is the problem..?
Quote from: Carceri on May 31, 2011, 02:32:32 AMQuote from: easyrider77 on May 30, 2011, 01:42:36 PM
When users logged in is more then 650 about, no one cant see the forum index. And when i unistall this mod the forum index works perfect. Have you idea what is the problem..?
No. Any errors in the log?
[28-May-2011 13:27:09] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
[28-May-2011 13:27:41] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
[28-May-2011 21:40:23] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
[28-May-2011 21:54:04] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
[28-May-2011 22:43:13] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
Quote from: easyrider77 on May 31, 2011, 08:31:03 AM
this is the latest errors in smf log .Code Select[28-May-2011 13:27:09] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
[28-May-2011 13:27:41] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
[28-May-2011 21:40:23] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
[28-May-2011 21:54:04] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
[28-May-2011 22:43:13] PHP Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 4630343 bytes) in /home/adultfor/public_html/forum/Sources/Subs-Package.php on line 2507
Quote from: Carceri on June 01, 2011, 05:25:07 AM
Does it help to allocate more memory for PHP, or is that out of memory error related to something different?
Quote from: igirisjin on June 05, 2011, 03:36:23 PM
Each membergroup can have a colour set for them (users names) - see individual settings for membergroups.
I think bold is for 'Buddies' but check that.
Quote from: easyrider77 on June 02, 2011, 08:12:31 AMQuote from: Carceri on June 01, 2011, 05:25:07 AM
Does it help to allocate more memory for PHP, or is that out of memory error related to something different?
This error come when i go to:
"update your forum" > Download Packages >Simple Machines Third-party Mod Site > [ Browse ]
Quote from: Celia N. Foster on June 07, 2011, 02:10:04 PM
Call to undefined function getUsersOnlineTodayStats() in /hermes/bosweb26b/b647/ipg.judithbarsicom/forum/Sources/BoardIndex.php on line 133
Quote from: khamseen on June 14, 2011, 09:02:58 AM
Fatal error: Cannot redeclare usersonlinetoday_settings() (previously declared in /home/khamseen/public_html/Sources/Subs-UsersOnlineToday.php:24) in /home/khamseen/public_html/trial/Sources/Subs-UsersOnlineToday.php on line 41
Quote from: Carceri on June 15, 2011, 05:13:53 AMQuote from: khamseen on June 14, 2011, 09:02:58 AM
Fatal error: Cannot redeclare usersonlinetoday_settings() (previously declared in /home/khamseen/public_html/Sources/Subs-UsersOnlineToday.php:24) in /home/khamseen/public_html/trial/Sources/Subs-UsersOnlineToday.php on line 41
What does line 41 in that file says? Mine does not have a redeclaration of the function on that line. Line 24 is where the function is first declared though.
Quote from: yakyakyak on June 09, 2011, 05:27:07 AM
Please advise the required edits in RC3 to remove these leftover icons in a non default theme after package removal
thank you
Quote from: Brack1 on June 15, 2011, 10:17:29 AMQuote from: Carceri on June 15, 2011, 05:13:53 AMQuote from: khamseen on June 14, 2011, 09:02:58 AM
Fatal error: Cannot redeclare usersonlinetoday_settings() (previously declared in /home/khamseen/public_html/Sources/Subs-UsersOnlineToday.php:24) in /home/khamseen/public_html/trial/Sources/Subs-UsersOnlineToday.php on line 41
What does line 41 in that file says? Mine does not have a redeclaration of the function on that line. Line 24 is where the function is first declared though.
You may have two lines the same in the file.
Quote from: aoife on June 16, 2011, 02:46:00 PM
After installing the latest version (1.6.0) to SMF 2.0, the mod does seem to work as it should but I get the following error message filling up my log:
***/forums/index.php?action=forum
2: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument
File: ***/forums/Themes/default/BoardIndex.template.php
Line: 183
Any ideas on how to fix?
Quote from: khamseen on June 20, 2011, 07:41:34 AMQuote from: aoife on June 16, 2011, 02:46:00 PM
After installing the latest version (1.6.0) to SMF 2.0, the mod does seem to work as it should but I get the following error message filling up my log:
***/forums/index.php?action=forum
2: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument
File: ***/forums/Themes/default/BoardIndex.template.php
Line: 183
Any ideas on how to fix?
Not without knowing what is on line 183 of your BoardIndex.template.
<a href="', $scripturl . '?action=post;board=', $board['id'] ,'"><img src="', $settings['images_url'], '/icons/post.gif" alt="*" title="', $txt['new_topic'],'" /></a>';
Quote from: aoife on June 20, 2011, 08:10:50 AMQuote from: khamseen on June 20, 2011, 07:41:34 AMQuote from: aoife on June 16, 2011, 02:46:00 PM
After installing the latest version (1.6.0) to SMF 2.0, the mod does seem to work as it should but I get the following error message filling up my log:
***/forums/index.php?action=forum
2: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument
File: ***/forums/Themes/default/BoardIndex.template.php
Line: 183
Any ideas on how to fix?
Not without knowing what is on line 183 of your BoardIndex.template.
Here's what it says on my line 183:Code Select<a href="', $scripturl . '?action=post;board=', $board['id'] ,'"><img src="', $settings['images_url'], '/icons/post.gif" alt="*" title="', $txt['new_topic'],'" /></a>';
Quote from: khamseen on June 20, 2011, 08:17:24 AMQuote from: aoife on June 20, 2011, 08:10:50 AMQuote from: khamseen on June 20, 2011, 07:41:34 AMQuote from: aoife on June 16, 2011, 02:46:00 PM
After installing the latest version (1.6.0) to SMF 2.0, the mod does seem to work as it should but I get the following error message filling up my log:
***/forums/index.php?action=forum
2: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument
File: ***/forums/Themes/default/BoardIndex.template.php
Line: 183
Any ideas on how to fix?
Not without knowing what is on line 183 of your BoardIndex.template.
Here's what it says on my line 183:Code Select<a href="', $scripturl . '?action=post;board=', $board['id'] ,'"><img src="', $settings['images_url'], '/icons/post.gif" alt="*" title="', $txt['new_topic'],'" /></a>';
Ok could you please upload the file so I can see it as a whole, just that line isn't part of the users online today mod, it is possible something has displaced the line though. What other mods do you have installed?
Quote from: Jessica. on June 20, 2011, 03:47:28 PM
how would this mod compare to this one? (http://www.simplemachines.org/community/index.php?topic=354049.msg3082631#new)
(no major differences?)
Quote from: Celia N. Foster on June 22, 2011, 07:41:33 PM
How exactly do I uninstall the mod?
Quote from: Carceri on June 23, 2011, 03:21:00 AMQuote from: Celia N. Foster on June 22, 2011, 07:41:33 PM
How exactly do I uninstall the mod?
The same way you would uninstall any other mod... through the package manager :)
Quote from: Celia N. Foster on June 22, 2011, 07:41:33 PM
My forum still has the same error when I try to log in. My forum is a RC 2.0.5.
The error I get is:
Fatal error: Call to undefined function getUsersOnlineTodayStats() in /hermes/bosweb26b/b647/ipg.judithbarsicom/forum/Sources/BoardIndex.php on line 133
How exactly do I uninstall the mod?
Please help!
Thank you.
Quote from: Celia N. Foster on June 22, 2011, 07:41:33 PM
Fatal error: Call to undefined function getUsersOnlineTodayStats() in /hermes/bosweb26b/b647/ipg.judithbarsicom/forum/Sources/BoardIndex.php on line 133
How exactly do I uninstall the mod?
Quote from: khamseen on June 20, 2011, 05:43:14 PM
Users Online Today mod lets you specify whether it covers the 'forum day', last 24 hours, or last 7 days. It also gives you a few options for how to arrange them and who can see it, Admins, registered users or everyone.
Quote from: yugo23 on June 27, 2011, 11:04:17 AM
Where can I find these options? All I can see is option to uninstall the mod and list files. Must be somewhere else, just I can't find it.
Quote from: WasdMan on June 23, 2011, 06:17:16 AM
Included in the Hungarian language files.
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo
'<br />[' . implode('] [', $context['membergroups']) . ']';
Quote from: Spoogs on July 02, 2011, 02:23:14 AM
Version 2.0RC1 of this mod duplicates the group key on the board index... not sure if this was intended.
Quote from: DasVON on July 05, 2011, 10:38:17 PM
I want to make a person or group not to be seen in the Users Online Today MOD at all ( I tried the invisible option)
Reason: I am using the Auto Respond Mod and I made a member called PR Bot I don't want him showing in the Group Key in the Users Online Today MOD
Can this be Done ?
Quote from: live627 on July 06, 2011, 08:06:35 PM
That hides a member from the online list, maybe not this mod. Certainly won't hide a membergroup from the key, either.
// "Users online" - in order of activity.
echo '
<div class="title_barIC" style="margin-top: -6px;">
<h4 class="catbg">
<span class="ie6_header floatleft">
<div class="floatleft" style="margin-top: 5px; width: 16px;">', $context['show_who'] ? '<a href="' . $scripturl . '?action=who' . '">' : '', '<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $context['show_who'] ? '</a>' : '', '</div><div class="floatleft" style="margin-left: 6px;">
', $txt['online_users'], '</div><br class="clear" />
</span>
</h4>
</div>
<p class="windowbg inline stats">
', $context['show_who'] ? '<a href="' . $scripturl . '?action=who">' : '', comma_format($context['num_guests']), ' ', $context['num_guests'] == 1 ? $txt['guest'] : $txt['guests'], ', ' . comma_format($context['num_users_online']), ' ', $context['num_users_online'] == 1 ? $txt['user'] : $txt['users'];
// Handle hidden users and buddies.
$bracketList = array();
if ($context['show_buddies'])
$bracketList[] = comma_format($context['num_buddies']) . ' ' . ($context['num_buddies'] == 1 ? $txt['buddy'] : $txt['buddies']);
if (!empty($context['num_spiders']))
$bracketList[] = comma_format($context['num_spiders']) . ' ' . ($context['num_spiders'] == 1 ? $txt['spider'] : $txt['spiders']);
if (!empty($context['num_users_hidden']))
$bracketList[] = comma_format($context['num_users_hidden']) . ' ' . $txt['hidden'];
if (!empty($bracketList))
echo ' (' . implode(', ', $bracketList) . ')';
echo $context['show_who'] ? '</a>' : '', '
</p>
<p class="windowbg inline 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 '
', sprintf($txt['users_active'], $modSettings['lastActive']), ':<br />', implode(', ', $context['list_users_online']);
// Showing membergroups?
// "Users online" - in order of activity.
echo '
<div class="title_barIC" style="margin-top: -6px;">
<h4 class="catbg">
<span class="ie6_header floatleft">
<div class="floatleft" style="margin-top: 5px; width: 16px;">', $context['show_who'] ? '<a href="' . $scripturl . '?action=who' . '">' : '', '<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $context['show_who'] ? '</a>' : '', '</div><div class="floatleft" style="margin-left: 6px;">
', $txt['online_users'], '</div><br class="clear" />
</span>
</h4>
</div>
<p class="windowbg inline 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 '
', sprintf($txt['users_active'], $modSettings['lastActive']), ': ', $context['show_who'] ? '<a href="' . $scripturl . '?action=who">' : '', comma_format($context['num_guests']), ' ', $context['num_guests'] == 1 ? $txt['guest'] : $txt['guests'], ', ' . comma_format($context['num_users_online']), ' ', $context['num_users_online'] == 1 ? $txt['user'] : $txt['users'];
// Handle hidden users and buddies.
$bracketList = array();
if ($context['show_buddies'])
$bracketList[] = comma_format($context['num_buddies']) . ' ' . ($context['num_buddies'] == 1 ? $txt['buddy'] : $txt['buddies']);
if (!empty($context['num_spiders']))
$bracketList[] = comma_format($context['num_spiders']) . ' ' . ($context['num_spiders'] == 1 ? $txt['spider'] : $txt['spiders']);
if (!empty($context['num_users_hidden']))
$bracketList[] = comma_format($context['num_users_hidden']) . ' ' . $txt['hidden'];
if (!empty($bracketList))
echo ' (' . implode(', ', $bracketList) . ')';
echo $context['show_who'] ? '</a>': '', '<br />', implode(', ', $context['list_users_online']);
// Showing membergroups?
Quote from: Kaitlyn on July 07, 2011, 04:48:32 AM
also wondering is it possible to completely remove (Visible: 0, Hidden: 0)
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_today'], ')';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
Quote from: Inti31 on July 12, 2011, 08:39:58 AM
Firefox makes the size bigger of all topics
Quote from: luuuciano on July 15, 2011, 01:36:45 PM
edit: something is adding an string that shows before the DOCTYPE... where is generated that? it is affecting the mod admin section too... that is why the looks gets mad I guess
Quote from: Carceri on July 15, 2011, 04:54:58 PMQuote from: luuuciano on July 15, 2011, 01:36:45 PM
edit: something is adding an string that shows before the DOCTYPE... where is generated that? it is affecting the mod admin section too... that is why the looks gets mad I guess
Could you post that string here?
Quote from: luuuciano on July 16, 2011, 02:52:17 PMbtw, what is for the xslt directory? it is needed/used?
QuoteIt's used (or at least was at some point) for helping applying the mod to unsupported themes.XML style sheets don't do that.
Quote from: luuuciano on July 15, 2011, 01:36:45 PMQuote from: Inti31 on July 12, 2011, 08:39:58 AM
Firefox makes the size bigger of all topics
That behavior is happening to me too... any idea about how to resolve it?
It looks too uggly that way... maybe its an unclosed tag or something?
I can not find anything in the code... neither looking at the parse... :(
edit: something is adding an string that shows before the DOCTYPE... where is generated that? it is affecting the mod admin section too... that is why the looks gets mad I guess
btw, here Im attaching spanish language files
Quote from: Individul on July 20, 2011, 12:29:03 PM
Well ist a great mod, but this problem make me to uninstall him.
If anybody find a solution for this problem, pls report here.
Quote from: luuuciano on July 20, 2011, 01:26:28 PM
Carceri, it looks like all your *.utf8 files have a BOM beggining
// If they are logged in, but statistical information is off... show a personal message bar.
// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
Quote from: Martine M on August 21, 2011, 03:58:12 AM
./Themes/argentum_enhanced_smf20final/BoardIndex.template.php Test failed
1. Add Before ./Themes/argentum_enhanced_smf20final/BoardIndex.template.php Test failed
Quote from: Martine M on August 19, 2011, 06:22:36 PM
I tried installing it manually but can't find in the boardindex.template.phpCode Select// If they are logged in, but statistical information is off... show a personal message bar.
were before I have to put thisCode Select// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
$context += getUsersOnlineTodayStats();
Quote from: noaccess on April 07, 2011, 04:11:09 AMQuote from: Carceri on April 06, 2011, 09:20:22 AMNonsense of course, just like the other argument used a few pages before. Any random fellow can register on the forum and get more access (see more) than just a nickname. Anyway, it doesn't matter, I already changed it.Quote from: noaccess on March 10, 2011, 01:40:33 AM
I would like to make Users logged in today visible to guests. How do I go about doing this? Also, why on earth would this be disabled by default? It should be the other way around.
For privacy reasons. It could reveal that a user was registered on a specific forum, to a visitor who was not registered on the same forum. Basically this is keeping in line with the rest of SMF that a guest is by default not allowed to view the list of registered users.
QuoteThe time period that the user list shows can be the current day, last 24 hours or last weekI see this mod can show who's on over the passed week, But don't now how to turn it on.
// Users Online Today
echo '
<div class="infocenter_section">
<h4 class="titlebg">', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '</h4>
<div class="windowbg">
<p class="section">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />
</p>
<div class="windowbg2 sectionbody">
<span><b><font color="#00FF00">';
echo
$txt['uot_total'], ' = ', $context['num_users_online_today'], '</b></font></span><font color="#ECD672">';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</font>';
Quote from: dbailey on October 11, 2011, 02:43:02 AM
My theme is silentwave_20rc3 and there is no BoardIndex.template.php file within this templates files, it must use the default one. The package installed with no troubles but it isn't showing up.
I'm using SMF 2.0.1 |
TinyPortal latest version.
Any ideas please?
Quote from: dbailey on October 11, 2011, 02:43:02 AMThis mod install only in ./Themes/default/BoardIndex.template.php . Try uninstall and install again (check core theme before).Tested SMF2.0.1+silentwave_20rc3+Users Online Today Mod
My theme is silentwave_20rc3 and there is no BoardIndex.template.php file
Quote from: T3CHN0 on October 11, 2011, 05:58:18 AMQuote from: dbailey on October 11, 2011, 02:43:02 AM
My theme is silentwave_20rc3 and there is no BoardIndex.template.php file within this templates files, it must use the default one. The package installed with no troubles but it isn't showing up.
I'm using SMF 2.0.1 |
TinyPortal latest version.
Any ideas please?
Are you sure it installed with no error's ?
I have a 2.0.1 beta site and on a fresh installed with your theme it installed
and also works perfectly.
maybe upload your files and I will have a look at them for you.
this is how it should look on the bottom of your theme
click on image to make bigger
// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
Quote from: dbailey on October 15, 2011, 02:26:46 AMsorry for a long wait in reply. got family over but will help when i can. I registered with your site and can see it not working if I click on forum.
Hi T3CHN0
Thanks for your help on this matter. I found the double up text and deleted it and made sure the right text is in the right place. But still no go. :(
Any other ideas?
Oh my address is www.christmasdisplays.co.nz (http://www.christmasdisplays.co.nz) you will need to register as a user then go to the forum link to see the users online info.
// Handle hidden users and buddies.
// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
Quote from: sharks on October 15, 2011, 07:20:56 AMdid you see this setting for member groups...
Hi Carceri Could you please consider adding a permission system to your mod, so that only certain membergroups are allowed to see the list of users online today. Thank you in advance.
Quote from: Branko. on October 08, 2011, 09:37:50 AM
SMF2.x - Modification Settings » Miscellaneous »The user list should cover the (current day, last 24 hours, last 7 days)
and Make the user list visible to (administrators, registered users, everyone) and also set Permissions>General Permissions select desired group then in general find View Who's Online (check or uncheck)
Quote from: sharks on October 15, 2011, 06:27:51 PMYou're right, Users Online Today v1.4.0 not have the same options...only 24h
But i'm using SMF 1.1.15...
Quote from: dbailey on October 16, 2011, 03:22:37 AMglade you got it working. yeah delete my reg if you could. happy to help when I can
Update *solved*
Did you want me to delete your registration on my site as well?
Quote from: 3fifty on October 25, 2011, 07:59:01 PM
Any updates for 2.0.1?
Quote from: T3CHN0 on October 08, 2011, 01:16:13 PM
If this is any good to someone, [My theme is blackrainV2].. The code for this mod didn't look good on my forum.
So I edited the code to look better on my forum...
BoardIndex.template.phpCode Select
// Users Online Today
echo '
<div class="infocenter_section">
<h4 class="titlebg">', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '</h4>
<div class="windowbg">
<p class="section">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />
</p>
<div class="windowbg2 sectionbody">
<span><b><font color="#00FF00">';
echo
$txt['uot_total'], ' = ', $context['num_users_online_today'], '</b></font></span><font color="#ECD672">';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</font>';
// Users Online Today
echo '
<div class="infocenter_section">
<h4 class="titlebg"><span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
<div class="windowbg2 sectionbody">
<span><b><font color="#ecd672">';
echo
$txt['uot_total'], ' = ', $context['num_users_online_today'], '</b></font></span><font color="#ECD672">';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</font>';
Quote from: roy123456789 on August 30, 2011, 03:50:49 PMTo make the users logged in today visible to guests:Quote from: noaccess on April 07, 2011, 04:11:09 AMQuote from: Carceri on April 06, 2011, 09:20:22 AMNonsense of course, just like the other argument used a few pages before. Any random fellow can register on the forum and get more access (see more) than just a nickname. Anyway, it doesn't matter, I already changed it.Quote from: noaccess on March 10, 2011, 01:40:33 AM
I would like to make Users logged in today visible to guests. How do I go about doing this? Also, why on earth would this be disabled by default? It should be the other way around.
For privacy reasons. It could reveal that a user was registered on a specific forum, to a visitor who was not registered on the same forum. Basically this is keeping in line with the rest of SMF that a guest is by default not allowed to view the list of registered users.
How did you change it? Code changes please
// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
// Users Online Today
echo '
<h4 class="titlebg"><span class="left"></span>
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', '<span>', $txt['uot_users_online_today'], '</span>
</h4>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
// if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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']);
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo
'<br />[' . implode('] [', $context['membergroups']) . ']';
}
echo '
</p>';
Quote from: rootuid on February 06, 2012, 04:21:37 PMRemove the permission from every rank in "Group Permissions". Administrators will get it by default regardless since they receive ALL permissions.
Works great on 2.0.2 but I want to restrict it to admins only. How do I achieve this ? Thanks
Quote from: Мel on May 10, 2012, 12:54:36 PM
Here what's wrong on the main page:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi47.tinypic.com%2Fx1drp1.jpg&hash=9c638e9e0d5ee97346c0d6fe6a7881516947dcce)
Quote from: Old Fossil on May 10, 2012, 12:56:03 PMQuote from: Мel on May 10, 2012, 12:54:36 PM
Here what's wrong on the main page:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi47.tinypic.com%2Fx1drp1.jpg&hash=9c638e9e0d5ee97346c0d6fe6a7881516947dcce)
I see nothing wrong with the mod myself.
I use the mod on my forum and see no differences.
Have a look at my Broadstar link in my sig if you would like to compare.
Quote from: Old Fossil on May 10, 2012, 01:10:02 PMI'm looking at it and can't see what's wrong at the first glance. Maybe you could see it better :)
Have a look at the themes index.template file and see if there is any code in there twice.
Quote from: Yoshi2889 on May 10, 2012, 02:41:01 PMWhere could I find it?
Nah, gimme ya BoardIndex.template.php instead :)
Quote from: Мel on May 10, 2012, 02:57:01 PMThe same directory you got the index.template.php from.Quote from: Yoshi2889 on May 10, 2012, 02:41:01 PMWhere could I find it?
Nah, gimme ya BoardIndex.template.php instead :)
I've got only BoardIndex.php from Sources.
Quote from: Yoshi2889 on May 10, 2012, 02:59:48 PMYep, it was with the defailt theme :)
The same directory you got the index.template.php from.
If it's not there gimme the one from the default theme.
// Users Online Today
echo '
<div class="infocenter_section">
<h4 class="titlebg">', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '</h4>
<div class="windowbg">
<p class="section icon">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '" />','
</p>
<div class="windowbg2 sectionbody">
<div class="inline smalltext">
', $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</div>
</div>
</div>';
// If they are logged in, but statistical information is off... show a personal message bar.
// Users Online Today
echo '
<div class="infocenter_section">
<h4 class="titlebg">', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '</h4>
<div class="windowbg">
<p class="section icon">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '" />','
</p>
<div class="windowbg2 sectionbody">
<div class="inline smalltext">
', $txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</div>
</div>
</div>
</div>';
Quote from: Old Fossil on June 06, 2012, 08:03:53 PMSure, try to register and then im going to set admin rights.
Can you please either open the forum to guests or give me temp admin ( via pm only) access so I can have a look for you.
Quote from: Castagna on June 06, 2012, 08:05:38 PMQuote from: Old Fossil on June 06, 2012, 08:03:53 PMSure, try to register and then im going to set admin rights.
Can you please either open the forum to guests or give me temp admin ( via pm only) access so I can have a look for you.
QuoteI am reporting this as unsafe on the mods page.
QuoteI am left with just a blank page, no error messages.
QuoteI am reporting this as unsafe on the mods page.
Quote from: Arantor on July 21, 2012, 10:17:48 PM
Waste of time. This mod is not unsafe - it installs and functions on a fresh install and has no known vulnerabilities (I've looked in the past) and the team will not remove it because of installation issues on your specific installation.
Quote from: Old Fossil on July 21, 2012, 10:15:53 PMQuoteI am reporting this as unsafe on the mods page.
The mod works as it should on 2.0.2
Did you uninstall the mod completely before upgrading?
Quote from: Arantor on July 22, 2012, 06:14:43 PM
It's not upsetting me, it's simply that it isn't actually unsafe, it just doesn't function on your specific forum for any one of many separate reasons, and none of them are 'unsafe', and the team will do precisely nothing for that reason - it isn't actually broken.
Quote from: ocmdiaz714 on September 02, 2012, 11:11:27 PM
Can somebody please tell me how to add space after the comma? Thanks.
Example:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi50.tinypic.com%2F16itw9j.gif&hash=7ac88977db625a78b2b1508e0fb2d4ae69d8704e)
Quote from: Bugo on September 05, 2012, 07:12:45 PM
Do you know PHP or HTML?
Quote from: Bugo on September 06, 2012, 02:29:43 AM
What version of SMF you're using, and what version of this mod you're installing?
$context['num_users_hidden_today']), ', '
Quote from: Bugo on September 06, 2012, 10:55:52 PM
I see no any problems. Space is exists:Code Select$context['num_users_hidden_today']), ', '
Maybe are you using other theme, with own BoardIndex.template.php? Can you post a link to your forum?
// 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['viewing_allowed'])
{
echo '
<br /><br />Users Online Today<br />';
echo
'', implode(',', $context['list_users_online_today']);
}
'<br />', implode(', ', $context['list_users_online_today']);
Quote from: Bugo on September 07, 2012, 12:58:23 AM
Why? :)
'<br />', implode(',', $context['list_users_online_today']);
Quote from: sajjad on September 21, 2012, 06:53:49 AM
hi
persian language for this mod
plz add bcz persian members need this mod
Quote from: Carceri on September 22, 2012, 12:53:51 PMsry
Thanks, but are you sure the UTF-8 version is correct? The other one seems to be UTF-8, but the one called -utf8 seems to be wrong.
Does it even make sense to have a non UTF-8 version for Persian language?
Quote from: sajjad on September 22, 2012, 03:06:34 PM
sry
i fix this problem
and change to utf-8
Quote from: glouk7 on October 25, 2012, 10:54:30 AMIt sounds like your template is at fault then. Double-check the changes you made and make sure you're not missing anything simple, such as closing tags, missing code, or mistakenly-made typos.
Hi guys,
The mod stopped to work for some reason and i can't find why.
I was using 2.0.1 version...and it was working fine till i changed template.
Then it doesn't work neither at new or the old template.
I've also upgraded the smf to 2.0.2 but still doesn't work
any idea?
Quote from: SugarD-x on October 25, 2012, 03:09:52 PMQuote from: glouk7 on October 25, 2012, 10:54:30 AMIt sounds like your template is at fault then. Double-check the changes you made and make sure you're not missing anything simple, such as closing tags, missing code, or mistakenly-made typos.
Hi guys,
The mod stopped to work for some reason and i can't find why.
I was using 2.0.1 version...and it was working fine till i changed template.
Then it doesn't work neither at new or the old template.
I've also upgraded the smf to 2.0.2 but still doesn't work
any idea?
Quote from: Yudd on November 01, 2012, 11:30:33 PMDid you encounter any errors on install? What version of SMF are you using? What other mods do you have installed?
I just installed this mod; however, it is not appearing on my site. How can this be fixed? Thanks.
Quote from: Colin on November 01, 2012, 11:39:35 PMQuote from: Yudd on November 01, 2012, 11:30:33 PMDid you encounter any errors on install? What version of SMF are you using? What other mods do you have installed?
I just installed this mod; however, it is not appearing on my site. How can this be fixed? Thanks.
Quote from: hcfwesker on November 02, 2012, 02:03:29 AMI went there and it shows the following:
Also check Administration Center > Modification Settings > Miscellaneous and activate it
Quote from: hcfwesker on November 03, 2012, 12:14:50 AM
Are you using a custom theme? if so, check the SMF Default theme and see if it shows there.
Quote from: hcfwesker on November 03, 2012, 04:58:27 PM
Well there ya go. You'll have to make the manual edits for BoardIndex.template.php on your custom theme. Parse the mod on the download page to see what the edits are.
Quote from: Yudd on November 01, 2012, 11:30:33 PMI have same problem
I just installed this mod; however, it is not appearing on my site. How can this be fixed? Thanks.
Quote from: CaviarDreams on November 06, 2012, 12:24:44 AM
Hello,
On my forum it's set so that members cannot hide their online status, making the "Hidden: 0" of the "Total: 123 (Visible: 123, Hidden: 0)" (or whatever the number is) very redundant. How do I remove the line "Hidden: 0"? (RC 2.0.2)
Thanks! :D
Quote from: hcfwesker on November 06, 2012, 04:29:24 AMhttp://www.simplemachines.org/community/index.php?topic=488756.msg3424698#msg3424698
Quote from: hcfwesker on October 21, 2012, 02:22:09 AMBoardIndex.template.phpI don't have a file called BoardIndex.template.php.
Find & Remove these lines.Code Selectif ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_today'], ')';
Quote from: CaviarDreams on November 07, 2012, 08:09:13 PMI don't have a file called BoardIndex.template.php.
Quote from: SugarD-x on December 17, 2012, 01:41:53 PMof course
Is this fully SMF 2.0.3 compatible?
Quote from: Infitima on December 25, 2012, 09:33:38 AMIt's a bug that oddly happens sometimes with this mod in various versions. Uninstall the mod via the Package Manager, then manually go through your forum's files that it modifies and remove all references to the mod. Then reinstall the package and it should only show up once. :)
Umm, when we upgraded to SMF 2.0.3 this MOD was installed, but afterwards it duplicated. YET, only for certain themes. (All of them but Default SMF Curve, and The Killing) the rest it shows on there twice. Both files that were edited have already been checked and show no duplicated lines.
Any idea what could be the problem? See http://shatteredplanes.com for what it's doing.
Quote from: teos55 on January 11, 2013, 12:49:04 PMInfocenter reports that there is one hidden, but actually "hidden" is unmarked in the forum settings.
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_today'], ')';
Quote from: aome on April 13, 2013, 02:20:13 AMThey are still banned. Their name just shows up there because they were logged in that day. Once the day ends and the "daily list" clears, they won't show up anymore since they can't access the forum.
Hello I got this mod and the one of Slashout banned members, when I ban a member is slashout in every part of the forum, except in this section, the one of the users online today, how can I make it to show it there too? Thank you.
Quote from: aome on April 13, 2013, 02:20:13 AM
Hello I got this mod and the one of Slashout banned members, when I ban a member is slashout in every part of the forum, except in this section, the one of the users online today, how can I make it to show it there too? Thank you.
mg.online_color, mg.id_group, mg.group_name
mg.online_color, mg.id_group, mg.group_name, mem.is_activated
// Buddies get counted and highlighted.
// Slash Banned Members ...
if ($row['is_activated'] > 10)
$row['real_name'] = '<s>' . $row['real_name'] . '</s>';
Quote from: hcfwesker on April 14, 2013, 12:14:11 PM
havent tested myself. so make a backup of the file so if it doesnt work just replace the file.
Quote from: Arantor on April 14, 2013, 12:44:53 PM
That won't work.
$row['is_activated'] will be 0 for unactivated members, 1 for activated, 2 through 5 for miscellaneous other states. Need to check it is > 10 not > 0
Quote from: aome on April 14, 2013, 12:59:10 PMSadly it didn't work... I don't get what might be the issue... tried with 10 and 0, but nothing, the name of the person remains without the slash.
Quote from: Aome on April 14, 2013, 01:07:55 PMHopefully there is a solution :)
// Slash Banned Members ...
if ($row['is_activated'] > 10)
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['id_member'] . '"><s>' . $row['real_name'] . '</s></a>';
Quote from: hcfwesker on April 14, 2013, 01:21:37 PM
Replace that 2nd part of the edit with this.Code Select// Slash Banned Members ...
if ($row['is_activated'] > 10)
$link = '<a href="' . $scripturl . '?action=profile;u=' . $row['id_member'] . '"><s>' . $row['real_name'] . '</s></a>';
Quote from: moonstreet on April 20, 2013, 04:24:19 AM
hi
I just did the large upgrade from 1.1.18 to 2.0.4 I had this mod before and it worked great. Is it 2.0.4 compatible? Do I need a new installation or can I just re install the the one I had, which is still in my package manager?
// Get the user online today list.
$context += getUsersOnlineTodayStats();
Quote from: MrNicotine on June 17, 2013, 06:22:41 PM
Trying to install 2.03 version, to smf 2.0 RC3, but no luck.
As soon as add in the part in /sources/boardindex.php, my forum page gives a 500 error..
Package installer wouldn't place this part, eventhough it gave no error...
Anyone an idea? I'm not sure what this part does, or where it calls toCode Select// Get the user online today list.
$context += getUsersOnlineTodayStats();
Quote from: Dijboy on October 19, 2013, 10:45:49 PM
How do I make this mod visible if I have a new theme installed?
2.0.5
Quote from: Asusrev on December 08, 2013, 10:49:28 AM
Problem solved!
Quote from: elosolipa on January 04, 2014, 01:49:34 AM
Hi, It is really usefull. But since I updated to SMF 2.0.6 it has a bug that shows an error when trying to post a reply to any topic. If You can check great!
Quote from: SirAlahn on January 31, 2014, 09:57:05 PM
Lacking that, is it possible to move where the list displays on the forum? I was hoping I could put it in the left panel sidebar of my forum, like how TinyPortal allows me to put blocks there.
Thank you in advance for your help.
Quote from: Nibogo on April 07, 2014, 06:09:16 PM
New 2.0.4 merging both packages (SMF 1.1.X and SMF 2.0) and also merging the three installation scripts (install.php, uninstall_optional.php, uninstall_mandatory.php) into db_install.php
Quote from: margarett on May 05, 2014, 02:06:44 PM
You shouldn't need to do it, the MOD already includes PT and PT_BR language files. You should find in Themes/default/languages the files
UsersOnlineToday.portuguese_brazilian.php
UsersOnlineToday.portuguese_brazilian-utf8.php
Quote from: Rk2910 on January 08, 2015, 05:33:39 AMIt should. :)
So now I wonder if this mod shows, to me, the hidden person in italics, in the list of people online today? Have to keep an eye on it.
Quote from: Rk2910 on January 08, 2015, 05:33:39 AM
ahHAAA - interesting. I searched for the definition of the italics I saw both on phpbb and smf with no luck - I always thought it meant they were posting at that time because sometimes I would see them regular and sometimes in italics. Mystery solved about that.
So now I wonder if this mod shows, to me, the hidden person in italics, in the list of people online today? Have to keep an eye on it.
Thanks Bruno.
Quote from: Rk2910 on February 06, 2015, 10:08:01 AMIf you mean the most users online in a single day of your forum's history, I believe SMF already logs and displays this by default in the stats section. If you mean a day-to-day status, I don't believe this mod does this by default, but I'm sure you could probably code it to do such.
So a new question - is it possible to store the number of users online today (I use the "Current day" mode which I assume is 12-12) when it kicks over to the next day? Maybe automatically at the time it starts over and also a on/off switch? Maybe store in a log file or a table or something? I never stay up late enough to see what my daily total was before it starts over again. This way I can see trends and such.
$txt['uot_users_online_last_24_hours']='Benutzer die letzten 24 Std. angemeldet';
$txt['uot_users_online_last_7_days']='Benutzer die letzten 7 Tage angemeldet';
Quote from: sangham.net on May 28, 2015, 11:50:16 AM
Nice tool and works fine, Mr Nibogo.
There have been two text strings not translated into German, if you like to add it.Code Select$txt['uot_users_online_last_24_hours']='Benutzer die letzten 24 Std. angemeldet';
$txt['uot_users_online_last_7_days']='Benutzer die letzten 7 Tage angemeldet';
Quote from: Steve on May 28, 2015, 08:01:16 AMYes "shy" sorry, haven't read it.
Did you read the first post? It clearly states one of the options is to show the last 24 hours. Having just installed it on my test forum I can verify that.
Quote from: Nibogo on September 23, 2015, 10:49:47 AMIf there are issues, then he is using mods or themes that aren't compatible with it. This mod works just fine in the latest version with no emulation needed.
Sure, but if there are issues for versions, version emulate should do it.
Quote from: Nibogo on November 06, 2005, 01:42:31 AM
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.
Quote from: lurkalot on February 14, 2017, 02:55:33 AMSMF Default Theme - Curve is the one yes.Quote from: Nibogo on November 06, 2005, 01:42:31 AM
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.
So are you using the default theme, or a different theme?
Quote from: Dylert on August 27, 2019, 05:14:15 PM
Is it possible to use this mod on SMF 2.1?
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '
<span class="membergroups">' . implode(', ', $context['membergroups']) . '</span>';
}
// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
Quote from: pocttopus on October 23, 2020, 04:19:52 PM
Please update this mod for 2.1rc3.
Quote from: Nibogo on April 29, 2021, 09:51:14 AMNo update yet.
I'll try to find sometime over the weekend to upgrade it for 2.1
Quote from: Nibogo on April 29, 2021, 09:51:14 AMYay!
I'll try to find sometime over the weekend to upgrade it for 2.1
Quote from: pocttopus on July 12, 2021, 07:46:20 AMMany mod authors prefer not to update their mods before a stable release, and at least I can very well understand that.
Hello, today v.2.1 RC4 is released -> https://www.simplemachines.org/community/index.php?topic=578135.0
And there is no update of this mod for 2.1 yet. :-\
Quote from: Hatshepsut on August 27, 2019, 11:38:21 PMQuote from: Dylert on August 27, 2019, 05:14:15 PM
Is it possible to use this mod on SMF 2.1?
Yes, this mod can run on SMF 2.1, you can see it in my forum:
https://bg-nacionalisti.org/BNF/index.php?action=forum
After mod installation, look in BoardIndex.template.php (for SMF 2.1 default theme)
Find:Code Select// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '
<span class="membergroups">' . implode(', ', $context['membergroups']) . '</span>';
}
Add after:Code Select// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
And you need to add some online.gif file to .../Themes/default/images/icons/
You can grab this image from my forum:
(https://bg-nacionalisti.org/BNF/Themes/CleanWhite21/images/icons/online.gif)
...or from any forum running SMF 1.x or 2.0.x, see it in Board index, section "Users online"
For example, that's default online.gif image, from this forum:
(https://static.simplemachinesweb.com/smf/default/images/icons/online.gif)
If you use another theme, you may need to perform these operations and for your current theme too.
// If they are logged in, but statistical information is off... show a personal message bar.
// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
Quote from: pocttopus on August 14, 2021, 10:32:18 AMIgnore that error and click install anyways! Then go into BoardIndex.template.php and then theses edits: (Make sure to back up first)
I am not able to install emulating this mod to 2.1RC4. :-\
I don't have this line inside BoardIndex.template.php file:Code Select// If they are logged in, but statistical information is off... show a personal message bar.
I need to add these lines before:Code Select// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
How can I solve this issue? :-\
Quote from: pocttopus on July 12, 2021, 08:33:15 AM
@Aleksi "Lex" Kilpinen
This is the fix and I cannot understand how tough can be this update? :-[Quote from: Hatshepsut on August 27, 2019, 11:38:21 PMQuote from: Dylert on August 27, 2019, 05:14:15 PM
Is it possible to use this mod on SMF 2.1?
Yes, this mod can run on SMF 2.1, you can see it in my forum:
https://bg-nacionalisti.org/BNF/index.php?action=forum
After mod installation, look in BoardIndex.template.php (for SMF 2.1 default theme)
Find:Code Select// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '
<span class="membergroups">' . implode(', ', $context['membergroups']) . '</span>';
}
Add after:Code Select// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
And you need to add some online.gif file to .../Themes/default/images/icons/
You can grab this image from my forum:
(https://bg-nacionalisti.org/BNF/Themes/CleanWhite21/images/icons/online.gif)
...or from any forum running SMF 1.x or 2.0.x, see it in Board index, section "Users online"
For example, that's default online.gif image, from this forum:
(https://static.simplemachinesweb.com/smf/default/images/icons/online.gif)
If you use another theme, you may need to perform these operations and for your current theme too.
$context += getMembersOnlineStats($membersOnlineOptions);
// Get the user online today list.
$context += getUsersOnlineTodayStats();
Quote from: pocttopus on February 26, 2022, 02:33:38 AMThis mod still works on 2.1.1?
// Showing membergroups?
if (!empty($settings['show_group_key']) && !empty($context['membergroups']))
echo '
<span class="membergroups">' . implode(', ', $context['membergroups']) . '</span>';
}
// Users Online Today
echo '
<div class="title_barIC">
<h4 class="titlebg">
<span class="ie6_header floatleft">
<img class="icon" src="', $settings['images_url'], '/icons/online.gif', '" alt="', $txt['online_users'], '" />', $txt['uot_users_online_'.$modSettings['uot_setting_period']], '
</span>
</h4>
</div>
<p class="inline smalltext">';
echo
$txt['uot_total'], ': <b>', $context['num_users_online_today'], '</b>';
if ($context['viewing_allowed'])
echo
' (', $txt['uot_visible'], ': ', ($context['num_users_online_today'] - $context['num_users_hidden_today']), ', ', $txt['uot_hidden'], ': ', $context['num_users_hidden_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['viewing_allowed'])
{
echo
'<br />', implode(', ', $context['list_users_online_today']);
}
echo '
</p>';
Quote from: pikeman on March 05, 2022, 03:56:44 PMIt is the same solution from the previous page. I tested it before and I tried it now, it doesn't work on my forum.What mods do you have installed if I may ask?
Quote from: pikeman on March 05, 2022, 03:56:44 PMIt is the same solution from the previous page. I tested it before and I tried it now, it doesn't work on my forum.
UsersOnlineToday.italian-utf8.php
and UsersOnlineToday.italian.php
(for backward compatibility with SMF 2.x)// Main page
$txt['uot_users_online_current_day']='Utenti di oggi';
$txt['uot_users_online_last_24_hours']='Utenti nelle ultime 24 ore';
$txt['uot_users_online_last_7_days']='Utenti negli ultimi 7 giorni';
$txt['uot_total']='Totale';
$txt['uot_visible']='Visibili';
$txt['uot_hidden']='Nascosti';
// Settings
$txt['uot_setting_sortby_pre_txt']='Ordina la lista utenti per';
$txt['uot_setting_username']='nome utente';
$txt['uot_setting_login_time']='tempo online';
$txt['uot_setting_sortby_post_txt']='';
$txt['uot_setting_sortorder_pre_txt']='Visualizza la lista utenti in';
$txt['uot_setting_ascending']='ordine crescente';
$txt['uot_setting_descending']='ordine decrescente';
$txt['uot_setting_sortorder_post_txt']='';
$txt['uot_setting_period_pre_txt']='La lista utenti dovrebbe coprire';
$txt['uot_setting_current_day']='il giorno corrente';
$txt['uot_setting_last_24_hours']='le ultime 24 ore';
$txt['uot_setting_last_7_days']='gli ultimi 7 giorni';
$txt['uot_setting_period_post_txt']='';
$txt['uot_setting_canview_pre_txt']='Rendi la lista utenti visibile per';
$txt['uot_setting_admin']='amministratori';
$txt['uot_setting_registered']='utenti registrati';
$txt['uot_setting_everyone']='tutti';
$txt['uot_setting_canview_post_txt']=''
Quote from: Nibogo on May 18, 2022, 01:33:18 PMNew version 2.2 released with support for SMF 2.1
Quote from: Shades. on May 18, 2022, 02:20:29 PMWorks great,Not so much for me. Each main index page view gives me one of each of these errors:
Hook call: function "UsersOnlineToday_boardindex" in file /profiles/k/kr/kra/krag/mydomain.cba.pl could not be called.
The callable UsersOnlineToday_boardindex could not be called.
Quote from: Arantor on February 09, 2024, 09:12:33 AMNo, they're in the smf_settings table. And isn't there a UI in admin for it?