Ion Auth - Lightweight Auth System based on Redux Auth 2 |
[eluser]vivekh[/eluser]
Is there a way to get the currently logged in users for a group? I see a method to get the active users but not the logged in users.
[eluser]malcomhfc[/eluser]
could you not do pseudo code not at my pc. Code: if(ion auth logged in) { Sent from Sony Ericsson Xperia Arc
[eluser]Ben Edmunds[/eluser]
You'd have to do a query against the DB sessions to get currently logged in users.
[eluser]rulin[/eluser]
Hi Ben I'm in the process converting my current project to Ion Auth 2 and I've noticed that the 'get_newest_users()' function (and others) has been removed. I had a dig around in the model and found the 'limit' and 'order_by' functions and had a try at reproducing 'get_newest_users()' using: Code: $this->ion_auth->limit(6); Any suggestions how I can code this? Also can I limit it to users of group 'members' only? The users() functions doesn't appear to reference the users_groups table. Regards Russ
[eluser]ibbrx[/eluser]
[quote author="rulin" date="1312729129"]Hi Ben I'm in the process converting my current project to Ion Auth 2 and I've noticed that the 'get_newest_users()' function (and others) has been removed. I had a dig around in the model and found the 'limit' and 'order_by' functions and had a try at reproducing 'get_newest_users()' using: Code: $this->ion_auth->limit(6); Any suggestions how I can code this? Also can I limit it to users of group 'members' only? The users() functions doesn't appear to reference the users_groups table. Regards Russ[/quote] This is simple! Change the limit to 1 as below and it will filter the latest record only. Code: $this->ion_auth->limit(1);
[eluser]rulin[/eluser]
Thanks for the reply ibbrx, Why should limit(1) work when limit(6) doesn't? (and it doesn't, I still get all users). Plus I want the 6 latest users, not just the 1 Russ
[eluser]DirkZz[/eluser]
What is the best practice for making the data of an user that has logged in globally accessible? Is there a standard function i missed? Because now ive just extended the CI_Controller.
[eluser]Go-Trex[/eluser]
Hi, I want to use Ion Auth 2 for a new project. I've set up my basic enviroment. Log in and creating a new user works perfect. But when I log in and want to go to /change_password an error occurs. The function get_user() does not excist in version 2 or am I missing it?
[eluser]rulin[/eluser]
[quote author="Go-Trex" date="1313190232"]Hi, I want to use Ion Auth 2 for a new project. I've set up my basic enviroment. Log in and creating a new user works perfect. But when I log in and want to go to /change_password an error occurs. The function get_user() does not excist in version 2 or am I missing it?[/quote] I don't think Ben has had a chance to update the user guide for V2 yet. The V2 function is user().
[eluser]michaelh99[/eluser]
Does "ion auth 2" use a different repo or is just what people are calling the code at http://github.com/benedmunds/CodeIgniter-Ion-Auth If it's something new I'd be interested in helping test and provide mods if there's room for another developer. edit - actually I'm interested in helping out with both but if there's a successor to ion auth in the works, I'm more interested in helping with that. |
Welcome Guest, Not a member yet? Register Sign In |