[eluser]xbonez[/eluser]
I'm testing adding items to the shopping cart like this:
Code:
$item = $this->model->getSingleItem();
for($i = 0; $i < 11; $i++) {
$this->cart->insert(array(
'id' => $item->id++,
'qty' => 1,
'price' => 1,
'name' => $item->title
));
}
However, the above loop only adds 10 items to the shopping cart. Even if I modify the loop above to run 20 times, I still get only 10 items in the cart. Is this a known bug, or am I doing something wrong?
Doing
Code:
echo count($this->cart->contents());
always shows a count of 10 or less. Never more.
I'm using CI 2.1.2. If someone can confirm they don't face this issue in a previous version, perhaps I can use the cart class from an older version of CI.