Welcome to Geeklog, Anonymous Sunday, December 22 2024 @ 07:20 am EST

Geeklog Forums

Secure Page


Rever

Anonymous
happy
Hello, How can I add some secure pages to my geeklog site which will only be accessible to the members.... ?? Any suggestion ?? Thank You.
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Well, you have the source - read it Wink You can use the global array $_USER to check if the current user is logged in or not:
Text Formatted Code
if ($_USER['uid'] > 1) echo "registered user";
else echo "anonymous user";
To check if the current user is in a certain group, you can use SEC_inGroup ('Group Name'). bye, Dirk
 Quote

All times are EST. The time is now 07:20 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content