[solved] FEU - checking if user is loggen in

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
urheat
Forum Members
Forum Members
Posts: 243
Joined: Sat Oct 17, 2009 6:50 am

[solved] FEU - checking if user is loggen in

Post by urheat »

Hi!

I know that with CustomContent-module I can check if user is logged in. But I try to limit module installations.

So - is it possible with Frontend User -module to check if user is logged in?

I would use this in page template, where normally is a login link and when user is logged in, I would like to change it to "edit your properties" or something.

Thanks!
Last edited by urheat on Thu Jul 18, 2013 4:25 pm, edited 1 time in total.
uniqu3

Re: FEU - checking if user is loggen in

Post by uniqu3 »

You can for example assign FEU module on top of oyur template like {FrontEndUsers form='silent' assign='foo'} then you will have all variables available after this module call.

If you put {get_template_vars} in your template you will see available variables, for FEU you could check for example against user id like( i think it was $userid)

Code: Select all

{if $userid != ''}
    <!--  do something for logged in user -->
{/if}
urheat
Forum Members
Forum Members
Posts: 243
Joined: Sat Oct 17, 2009 6:50 am

Re: FEU - checking if user is loggen in

Post by urheat »

Thanks uniqu3!

This works fine :)

If I have {FrontEndUsers form='silent' assign='foo'} in page template, do I have to set pages cache-options somehow (the login page is non-cachable)?

And does this method have effect to page load times?
Post Reply

Return to “Modules/Add-Ons”