[eluser]dexter21[/eluser]
hi,
i have several productos with session vars:
echo $this->session->set_userdata('productid','2323232');
echo $this->session->set_userdata('description','test1');
echo $this->session->set_userdata('productid','232');
echo $this->session->set_userdata('description','text2 ');
echo $this->session->set_userdata('productid','23111');
echo $this->session->set_userdata('description','test4');
now i want to recover all products_id with a for. How could i read all session variables of the same type with a for ?
i tried:
for ($a=0;$a<sizeof($this->session->userdata);$a++)
{
echo $this->session->userdata('product_id',$a)."<br>";
}
any ideas? many thanks