Welcome Guest, Not a member yet? Register   Sign In
Redux Authentication 1.4a (24th July 2008)

[eluser]CARP[/eluser]
[quote author="Mat-Moo" date="1225328547"]I moved from 1.6 to 1.7 using this no issues. Make sure you updated your session tables as required.[/quote]

Yes, I followed the upgrading guide, all went ok, did the sql patch, etc.
Will check everything again

[eluser]hugle[/eluser]
I was getting all the time this error:

Fatal error: Call to a member function set_rules() on a non-object in /var/www.....

I have put 'validation' to $autoload['libraries'] (config/autoload.php);
the error disappeared.

CI 1.7


Hope that helpes someone..
NBow I will try to make a login page, then registration.

Thanks and Good luck.

[eluser]CodeIgniterNoob[/eluser]
I keep hitting this error after trying to register:



A Database Error Occurred
Error Number: 1054

Unknown column 'user_data' in 'field list'

UPDATE `sessions` SET `last_activity` = '1226272392', `user_data` = 'a:1:{s:2:\"id\";s:1:\"4\";}' WHERE `session_id` = '8412f3c1dce16047987c94c9ae2c3295'




And this after trying to register again:


Disallowed Key Characters




I followed the instructions. It might be just me, but theres not really much documentation
for this library.

[eluser]Pascal Kriete[/eluser]
@NuclearArt this isn't a Redux problem.
If you've updated to CI 1.7 recently you will need to add a user_data field to your session table.

[eluser]CodeIgniterNoob[/eluser]
Stupid question. Im trying to protect a page, so if session doesnt exist it redirects, else it stays. But it always redirects.

How do I protect a page with Redux?

Code:
if($this->session->userdata('id'))
    {
        return true;
    }
    else
    {
        redirect('/welcome/');    
}

[eluser]McNoggin[/eluser]
That should work, but you need to display something instead of just returning true. Also it looks like you are missing a closing }

[eluser]CodeIgniterNoob[/eluser]
[SOLVED]

No, it keeps logging me out to the login screen.

I ran this test:
Code:
if(($this->session->userdata('id')) == "")
    {
        echo 'not logged in';
    }
    else
    {
        echo 'logged in';
    }

It always writes not logged in.

And tried this:

Code:
if(!$this->redux_auth->logged_in()) {
     redirect('/welcome/');    
}
else {
     echo 'Welcome!';
}

It redirects me.

What can be the problem? How does Redux normally protect pages? I didnt find any documentation on that.

[SOLUTION]

I had $config['sess_cookie_name'] = 'ci_session'; commented out.

This is not really a solution, just a mistake.

[eluser]CARP[/eluser]
Hi guys
Does any1 know how to assign different user levels to users?
For example, to asssign group_id = 1 to the first user (admin) and then group_id = 2 to the rest of the users ?
And, how to check their level in the login function?

Thanks a lot in advance,

[eluser]Unknown[/eluser]
Hi guys, can anyone please help me? I'm encountering an error. I'm not sure what to do. Thanks!

The error is:

A PHP Error was encountered

Severity: Notice

Message: Undefined property: User::$validation

Filename: controllers/user.php

Line Number: 11

Fatal error: Call to a member function set_rules() on a non-object in C:\xampp\htdocs\HKPost\system\application\controllers\user.php on line 11

It seems that the set_rules function has not been defined yet. Would anyone know where I can do that? I basically just copy and pasted everything.

[eluser]McNoggin[/eluser]
Sounds like you are not loading the validation library. Add this line before line 11 in that file

$this->load->library('validation');

Or you could always set it up to load everytime.




Theme © iAndrew 2016 - Forum software by © MyBB