That's a condition to eliminate guests. Get rid of that "if" statement. If the clause is a "if ... else ...", get rid of the "if" condition, and then get rid of everything under the "else".
no i don't u think u understood what i asked
what i wanted was so that the guests could see who is online
is that what u answered or did u answer how to remove the guests from the online list?
thanxz
That "$Context->Session->UserID > 0" condition is what's keeping guests from seeing the WhosOnline Panel (I believe)... Now that I look at it, it's not quite as simple as erasing the condition (because there's a preference involved). You would probably need to change it to:
Note the NOT operator ("!") and the parenthesis. Try that out. It might work, or it might not. If it doesn't, I would have to look deeper at the code to see what else is going on.
Comments
if ($Context->Session->UserID > 0) { ... }
That's a condition to eliminate guests. Get rid of that "if" statement. If the clause is a "if ... else ...", get rid of the "if" condition, and then get rid of everything under the "else".
Are you following me?
if (in_array($Context->SelfUrl, array("account.php", "categories.php", "comments.php", "index.php", "post.php", "search.php", "settings.php")) && $Context->Session->UserID > 0 && !$Context->Session->User->Preference("HideWhosOnline")) {
That "$Context->Session->UserID > 0" condition is what's keeping guests from seeing the WhosOnline Panel (I believe)... Now that I look at it, it's not quite as simple as erasing the condition (because there's a preference involved). You would probably need to change it to:
if (in_array($Context->SelfUrl, array("account.php", "categories.php", "comments.php", "index.php", "post.php", "search.php", "settings.php")) && !($Context->Session->UserID > 0 && $Context->Session->User->Preference("HideWhosOnline"))) {
Note the NOT operator ("!") and the parenthesis. Try that out. It might work, or it might not. If it doesn't, I would have to look deeper at the code to see what else is going on.