The last level array of goods contains the name, price, and quantity of a single product. Should its name be goods[$i]['name']? I hope experts can answer it
癸亥王2018-06-28 10:35:35
The code of this buy.php is wrong. $goods = $_SESSION['goods']; and $_SESSION['goods'] = $goods; are not needed. $goods[$name]['*'] should be written as $goods['goods'] [$name]['*']
PHP中文网2018-05-22 12:26:51
Multi-dimensional array You will know it after trying it. If you don’t have the code, we can’t answer it