| Re: How do I stop guests from viewing registered user profiles? |
| by scrapie on 2004/6/6 3:42:36 This is great thanks! Works like a charm.
|
| Re: How do I stop guests from viewing registered user profiles? |
| by treefrog on 2004/4/24 21:02:52 I answered my own question. Sorry. I had forgotten to close the if clause. that's all. Now I can do it any way I please. That's what happens when you're learning! |
| Re: How do I stop guests from viewing registered user profiles? |
| by treefrog on 2004/4/24 20:56:26 I tried both: $xoopsUser or redirect_header('index.php', 3, _NOPERM); and the if clause version above. Both only render a completely blank page for me when I test it out as a guest user... am I missing something? Is it possible to add a: <{if $xoops_isuser}> somewhere in the template instead? If so, where would be the best place? Could I actually just plug it in the certain boxes in the table for just the info I'd like covered? (i.e., the email address) I'm sorry to sound like a ditz... I'm still trying to understand PHP... |
| Re: How do I stop guests from viewing registered user profiles? |
| by ajaxbr on 2004/3/22 17:25:32 Thanks a lot, Dave... this is much more elegant, so nobody can say it's an ugly hack anymore ![]() I just skimmed over /kernel/user.php and saw a "rank()", a "&getGroups()" and a "isAdmin()" in there... Could anyone who knows his/her PHP give us a hint about how to use this to check whether an user has Perhaps something like le="color: #000000"><?php $uid = uid(); $xoopsrank = rank(uid) if !($xoopsrank == "Webmaster" || $xoopsrank == "Moderator" || $xoopsrank == "Masterator") { redirect_header('index.php',3,_NOPERM); exit(); } (sorry, no habla php)
|
| Re: How do I stop guests from viewing registered user profiles? |
| by Dave_L on 2004/3/22 15:23:24 Here's a more concise way of doing it: le="color: #000000"><?php $xoopsUser or redirect_header('index.php', 3, _NOPERM); |