I need to write some code which removes items from a basket and if the user wants to add another of the same item (increment the quantity by one).
The code which makes up the basket is as follows :
<?php
session_start();
// make up item to go in shopping basket
$item = array();
$item['ProductCode'] = $GET['ProductCode'];
$item['Description'] = $GET['Description'];
$item['Price'] = $_GET['Price'];
$item['Quantity'] = 1;
// add item to end of shopping basket
$_SESSION['basket'][] = $item;
require "list.php";
?>
Any suggestions?