views:

81

answers:

2

Has anybody been able to implement a "remember me" feature with CodeIgniter's FreakAuth Library?

A: 

I currently use the library TankAuth and that has a "Remember me" function in it. You could use that or implement the way they do it in FreakAuth.

http://www.konyukhov.com/soft/tank_auth/

Kieran Andrews
A: 

I don't use freakauth, I just do those things in my own custom library. However, I needed this feature and was having troubles getting something to work until someone pointed me here:

http://codeigniter.com/wiki/PK_Session/

It works great for me. I would guess it works with the freakauth library too. Basically, in your controller you see if remember me was checked, then you call:

$this->session->cookie_monster($this->input->post('remember_me') ? FALSE : TRUE);

It then can set another cookie that stores if the other should be remembered.

There's more to it, but just read through the code to get an idea of how it works.

Matthew