PortalParts.com Site

 Forum Index > Geeklog > FAQ Manager Plugin New Topic Post Reply
 FAQman and Security
 |  Printable Version
 July 23 2004 14:56 PM  
Forum Admin

Status: offline

Registered: 03/01/02
Posts: 3576

Well you probally want to use somethink like this logic to check if the user DOES has that permission - then show an error message - else continue.

PHP Formatted Code

if (!SEC_hasRights('faqman.user')) {
    $display .= COM_siteHeader ('menu');
    $display .= COM_startBlock ($MESSAGE[30], '',
                                COM_getBlockTemplate ('_msg_block', 'header'));
    $display .= $MESSAGE[31];
    $display .= COM_endBlock (COM_getBlockTemplate ('_msg_block', 'footer'));
    $display .= COM_siteFooter ();
    COM_accessLog("User {$_USER['username']} tried to illegally access the FAQ main module.");
    echo $display;


Please consider contributing to support my efforts ..
Profile Email Website PM
 July 26 2004 09:25 AM  
Forum Newbie

Status: offline

Registered: 07/23/04
Posts: 2

That worked perfectly--thanks Blaine!!

For everyone's future reference, I inserted this code after line 61 of the public_html/faqman/index.htm. By creating a user Group called "FAQ Reader" and assigning it the permission faqman.user, you can assign read access to the FAQs on a user-by-user basis.

Profile Email PM
Content generated in: 0.16 seconds
New Topic Post Reply

 All times are CST. The time is now 07:48 AM.
Normal Topic Normal Topic
Locked Topic Locked Topic
Sticky Topic Sticky Topic
New Post New Post
Sticky Topic W/ New Post Sticky Topic W/ New Post
Locked Topic W/ New Post Locked Topic W/ New Post
View Anonymous Posts 
Anonymous users can post 
Filtered HTML Allowed 
Censored Content