Revision 180 | Revision 182 | Zur aktuellen Revision | Blame | Vergleich mit vorheriger | Letzte Änderung | Log anzeigen | RSS feed
<?php/*** @author Lars Tiefland* @copyright 2016*/class Basket extends CI_Controller{public function __construct(){parent::__construct();if (!@is_array($_SESSION['SHOP']['BASKET'])){$_SESSION['SHOP']['BASKET'] = array();}}public function add(){$item = array('ID' => $this->input->post('item'),'menge' => $this->input->post('Menge'),'preis' => $this->input->post('preis'),);$id = implode('-', $item);// trigger_error(var_export($this->input->post(), true), E_USER_WARNING);$_SESSION['SHOP']['BASKET'][sha1($id)] = $item;}public function update($bId, $menge = 1, $preis = 0){}function index(){$this->view->load('basket.tpl');}}?>