MeNeedz Auth - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22) +--- Thread: MeNeedz Auth (/showthread.php?tid=13058) |
MeNeedz Auth - El Forum - 12-29-2008 [eluser]opel[/eluser] this is set in the Auth library var $user_standard_group = 'user'; Andy my config/auth file is as follows : Code: $config['input_config'] = array( Both of them didn't seem to work in setting the standard group id field into my "user" table although maybe I have it wrong and they go into another table field ? Thanks MeNeedz Auth - El Forum - 12-29-2008 [eluser]davidbehler[/eluser] Looks right to me. What is set for the user group instead of 'user'? MeNeedz Auth - El Forum - 12-30-2008 [eluser]opel[/eluser] Nothing I have set user as the group_id and group level of 1 in the database too? MeNeedz Auth - El Forum - 12-30-2008 [eluser]davidbehler[/eluser] What's the type of the group_id field in your user table? MeNeedz Auth - El Forum - 01-05-2009 [eluser]Mat-Moo[/eluser] Just an idea, but how about taking a parameter in to the register function that can contain othere data for the user to add to the table. e.g. function register($userdata) { ... $_data = array_merge($userdata,$data); $result = $this->CI->db->insert($member_database_config['name'], $_data); } MeNeedz Auth - El Forum - 01-05-2009 [eluser]Mat-Moo[/eluser] I'm trying to add some activation in to my code. When a user registers, I now fill out the rest of the record and send an email with an activation code. In my login code, if login was ok, I then check the active field to see if the account was activated. If not another email is sent with details and a warning sent.... However if I have "if($this->auth->is_logged_in())" in my view file - it returns true? I tried the basic if ($this->auth->user["Activated"]=="FALSE") { $who=$this->auth->user["RecordID"]; $this->auth->logout(); $this->user_model->email_validation($who); } MeNeedz Auth - El Forum - 01-08-2009 [eluser]Mat-Moo[/eluser] Picking up on the last message I posted, I ended up using "$this->session->set_userdata('user',FALSE); // fake logout" to remove the user data, rather than destroy the whole session (which lost other session data I needed). MeNeedz Auth - El Forum - 02-02-2009 [eluser]ray73864[/eluser] Hi Waldmeister, Love the library, have been using it for a while now, quick question, could you create a function for getting the name of a group? eg: $this->auth->group_name(100) might return 'administrator'? It isn't essential, i could come up with a normal select statement to grab it, i just thought that others might be able to benefit from such a function too. MeNeedz Auth - El Forum - 02-02-2009 [eluser]davidbehler[/eluser] @Mat-Moo: I updated the logout function to no longer destroy the session but rather set the user variable to false as you proposed. @ray73864: There is no such thing as a group name in the original version of my library, the only infos on a group are its id and its level. I might add that column and a corresponding function to retrieve the name if there is need for such things MeNeedz Auth - El Forum - 02-21-2009 [eluser]charlie spider[/eluser] great lib, i'm enjoying it a lot for passwords, specifically when using the password generator, is there any reason why i can't do the following ? Code: var $_encryption_methods = array('md5', 'sha', 'sha1'); assuming i escape everything upon input and output. Thanks |