Welcome Guest, Not a member yet? Register   Sign In
Community Auth Learning...
#51

(This post was last modified: 12-05-2015, 04:34 PM by solidcodes.)

Admin CPanel working very fine now in my Localhost.
another +1 for that very helpful codes from you.

Last question I hope,
How do you properly implement 'Remember me' in community-auth.

thanks in advance.
No SEO spam
Reply
#52

(12-05-2015, 04:33 PM)solidcodes Wrote: Admin CPanel working very fine now in my Localhost.
another +1 for that very helpful codes from you.

Last question I hope,
How do you properly implement 'Remember me' in community-auth.

thanks in advance.

Look at the example login form, in the Community Auth views. You will see this:


PHP Code:
<?php
    if
config_item('allow_remember_me') )
    {
?>

    <br />

    <label for="remember_me" class="form_label">Remember Me</label>
    <input type="checkbox" id="remember_me" name="remember_me" value="yes" />

<?php
    
}
?>



What this means is that all you need to do to turn on the remember me feature is set "remember_me" to TRUE in config/authentication.php. This is documented on the Community Auth website, as well as the other configuration needed to customize the remember me feature. See here:

http://community-auth.com/documentation/...cation-php
Reply
#53

(This post was last modified: 12-08-2015, 06:30 PM by solidcodes.)

Thanks
I already set "remember_me" to TRUE.
The check box show-up but here is my problem.
When the check box is not checked and I tried to login and close the browser and re-open the browser.
I still see the username. Eventhough the remember-me check-box is not checked?

Here is the codes I use to show the username
Code:
$this->auth_user_name;

Any advice?

Thanks in advance.
No SEO spam
Reply
#54

(12-08-2015, 05:03 PM)solidcodes Wrote: Thanks
I already set "remember_me" to TRUE.
The check box show-up but here is my problem.
When the check box is not checked and I tried to login and close the browser and re-open the browser.
I still see the username. Eventhough the remember-me check-box is not checked?

Here is the codes I use to show the username
Code:
$this->auth_user_name;

Any advice?

Thanks in advance.

The session is handled bi CI, so maybe check your settings in config/config?
Reply
#55

I already set the session_expire to zero.
Code:
$config['sess_expiration'] = 0;

But the chrome browser still remember the username?
What am I missing here?

thanks in advance.
No SEO spam
Reply
#56

After you close the browser and come back, what does the cookie console say? I use Firebug on Firefox, but I think Chrome has a cookie console too.
Reply
#57

This is cookie console says in Google Chrome.
http://postimg.org/image/ap1tlxfkh/

Thanks
No SEO spam
Reply
#58

When I set the session expires to 0, my Chrome sayings the Expiration / Max-Age is "Session". I don't know what to tell you about that, because this is CI not Community Auth.
Reply
#59

(This post was last modified: 12-11-2015, 06:44 PM by solidcodes.)

Okay thanks for letting me know that it's CI's problem.
But I hope someone can help me fix this.

@Narf are you there? lol
No SEO spam
Reply
#60

(08-20-2015, 09:10 PM)solidcodes Wrote:
(08-20-2015, 07:41 PM)skunkbad Wrote:
(08-20-2015, 06:32 PM)solidcodes Wrote: @Brian
Do you have documentation on how to install and use Community-Auth properly under HMVC, specially wiredesignz HMVC?
If hope there is...

I have never felt the need to use HMVC with CI, and as a special customization, you would need to figure out integration on your own.

Okay will figure out myself.
Thanks again for your answer.

I have integrated to HMVC successfully. The only thing to do is to copy file /app/third_party/community_auth/config/form_validation/login.php to /app/config/ folder. You need to do this because in HMVC it reloads the config only in /app/config.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB