[prev in list] [next in list] [prev in thread] [next in thread] 

List:       nextgen-online
Subject:    Re: [Nextgen-online] Modules which does not require login
From:       "Frank Tilugulilwa" <tilugulilwa () gmail ! com>
Date:       2008-08-29 7:23:11
Message-ID: c082069e0808290023x73f41dd2ga7a17d23b84d40c0 () mail ! gmail ! com
[Download RAW message or body]

On Thu, Aug 28, 2008 at 12:56 PM, Tohir Solomons <tsolomons@uwc.ac.za>wrote:

>
>
> On Thu, 2008-08-28 at 12:42 +0300, Frank Tilugulilwa wrote:
> > Can anyone assist  me on the list/examples of all modules which do not
> > require login to access them.
> >
> > My intention is to understand how requiresLogin works? and how to
> suppress
> > it.
> >
>
>
> difficult to give you the list, but you could do so yourself. The key
> function is requiresLogin in the the controller.
>
>
> function requiresLogin($action)
> {
>    $loginRequired = array ('action1', 'action3');
>
>    if (in_array($action, $loginRequired)) {
>        return TRUE;
>    } else {
>        return FALSE;
>    }
> }
>
>
> This means the following actions do no require login:
>
> index.php?module=mymodule
> index.php?module=mymodule&action=action2
> index.php?module=mymodule&action=action4
>
>
> BUT the following will require login
>
> index.php?module=mymodule&action=action1
> index.php?module=mymodule&action=action3
>
> By default, all modules return TRUE for that function
>
> To turn it off completely:
>
> function requiresLogin()
> {
>    return FALSE;
> }


Nice tutorial, I am happy with this.
_______________________________________________
Nextgen-online mailing list
Nextgen-online@mailman.uwc.ac.za
http://mailman.uwc.ac.za/mailman/listinfo/nextgen-online
See the posting rules:
http://oldavoir.uwc.ac.za/avoir/index.php?module=wiki&amp;action=wikilink&amp;pagename=MailingListRules


All Email originating from UWC is covered by disclaimer 
http://www.uwc.ac.za/portal/public/portal_services/disclaimer.htm 


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic