Welcome Guest, Not a member yet? Register   Sign In
Session Unset
#1

[eluser]The Casual Bot[/eluser]
Hey Guys

iv tried and tried but cant get it to work



Code:
$i = 1;
     echo $i;
     echo '<pre>';
     while ($i <= $data['personalnumber']) {

      $this->app = $this->load->database('default', TRUE);
      print_r ($this->session->userdata($i));
      $this->session->unset_userdata($i);
      print_r ($this->session->userdata($i));
      $i = $i + 1;
      echo $i;
        }
      echo '</pre>';

I can unset if i change $i to say '1' which at the first loop $i == 1 but it will not clear the session data id i pass it a variable

as you can see from my code i have tried to resolve this
but it gives no error and leaves the data in the session

Any Ideas

Thanks
AJ
#2

[eluser]The Casual Bot[/eluser]
it's OK

iv fixed it

i had to pass in an array (as it said in the user guide) *tut*

Smile

Thanks

Aj




Theme © iAndrew 2016 - Forum software by © MyBB