Welcome Guest, Not a member yet? Register   Sign In
Expired session & csrf_protection
#3

[eluser]ci_user[/eluser]
[quote author="CroNiX" date="1338495649"]The way they coded it, the only way is to extend the CI_Security class and override the csrf_show_error() method with your own.[/quote]

Ok, I'm trying that but how can I redirect in the csrf_show_error method?
Code:
public function csrf_show_error()
    {
        // show_error('The action you have requested is not allowed.');
  redirect('myController');
     }
Gives me the error "Call to undefined function redirect()".
Code:
public function csrf_show_error()
    {
        // show_error('The action you have requested is not allowed.');
   $this->load->helper('url');
   redirect('benefits');
     }
Gives me the error "Call to a member function helper() on a non-object".

Am I missing something?


Messages In This Thread
Expired session & csrf_protection - by El Forum - 05-31-2012, 01:04 PM
Expired session & csrf_protection - by El Forum - 05-31-2012, 01:20 PM
Expired session & csrf_protection - by El Forum - 06-01-2012, 07:37 AM
Expired session & csrf_protection - by El Forum - 06-01-2012, 09:41 AM
Expired session & csrf_protection - by El Forum - 06-01-2012, 09:56 AM



Theme © iAndrew 2016 - Forum software by © MyBB