Cart shows content only sometimes - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Cart shows content only sometimes (/showthread.php?tid=53605) |
Cart shows content only sometimes - El Forum - 07-31-2012 [eluser]Unknown[/eluser] I have huge problem with cart library of codeigniter. It seems that it shows content only sometimes. I don't know why. When I insert new item to cart content in insert_to_cart page and call var_dump($this->cart->content()) - it show entire cart content. Everything is ok. Problem starts when i call var_dump($this->cart->contents()); in index, for example. It don't show content of cart at all, it shows zero, empty array... But if I call it again in insert_to_cart page, than content is untouched. Some other informations from config.php Code: $config['sess_cookie_name'] = 'ci_session'; Please, help. Cart shows content only sometimes - El Forum - 08-10-2012 [eluser]srpurdy[/eluser] [quote author="Smokie" date="1343747142"]I have huge problem with cart library of codeigniter. It seems that it shows content only sometimes. I don't know why. When I insert new item to cart content in insert_to_cart page and call var_dump($this->cart->content()) - it show entire cart content. Everything is ok. Problem starts when i call var_dump($this->cart->contents()); in index, for example. It don't show content of cart at all, it shows zero, empty array... But if I call it again in insert_to_cart page, than content is untouched. Some other informations from config.php Code: $config['sess_cookie_name'] = 'ci_session'; Please, help.[/quote] Try This instead. Code: $config['sess_cookie_name'] = 'cisession'; I also had issues with useragent match being on. I think that's where the problem is, but encrypt cookie imo should always be on also. |