How to display webpage to staff only?

trakstarz

New Member
Jul 21, 2011
14
0
I am using UberCMS

Can anybody provide me with the code to allow only staff members (rank 6 or higher) to view a page in my uberCMS?

I have a feeling i need to edit my database table (site_navi) and generic_top.tpl. Thanks in advance!
 

brsy

nah mang
May 12, 2011
1,530
272
I am just starting out with PHP, so I believe its something that goes into the users table and checks user rank. if rank is over 6, then it allows then. If it isnt, it shows an error page. I will try to research the exact code.
 

trakstarz

New Member
Jul 21, 2011
14
0
I am just starting out with PHP, so I believe its something that goes into the users table and checks user rank. if rank is over 6, then it allows then. If it isnt, it shows an error page. I will try to research the exact code.

What im trying to do is add a new page to my site navigation which each page in my ubercms is listed in database table, site navi. And then generic_top.tpl has the PHP code to control who can view each page, etc.

So, all i really need is the code to add to generic_top.tpl that gets the users rank and if rank is above 6, then it will show the new page on my site navigation. If the rank is below 6, well then it just doesn't show the tab, period. Do you know the code to do this? Thanks in advance!
 

brsy

nah mang
May 12, 2011
1,530
272
What im trying to do is add a new page to my site navigation which each page in my ubercms is listed in database table, site navi. And then generic_top.tpl has the PHP code to control who can view each page, etc.

So, all i really need is the code to add to generic_top.tpl that gets the users rank and if rank is above 6, then it will show the new page on my site navigation. If the rank is below 6, well then it just doesn't show the tab, period. Do you know the code to do this? Thanks in advance!
I am not too sure, so you can probably try to rip it from housekeeping. :)
 

Kieren

The OGz
Aug 4, 2010
2,957
751
You'll need to edit community_header and put in if($user->user("rank") > 4) the page itself can be displayed no one has been bothered to code something like that but if you want the webpage hyper-link to act like the housekeeping then do it that way.
 

Users who are viewing this thread

Top