Pergunta

I'm using the Codeingiter cart class for a simple ordering system, I've managed to get the cart working fine, but I'm struggling to think how i go about saving the contents of the cart as an "order" in a database table so that the administrator can process it/view it.

I know the class stores the data in a session table, but it seems quite hard to deduce what is being stored - so I'm a bit confused as to where to start!

Foi útil?

Solução

use

$this->cart->contents();

at the checkout time to get all the products details in the cart, and add them in the order tables.

Refer this for the cart class functions.

http://ellislab.com/codeigniter/user-guide/libraries/cart.html

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top