Cart not functioning properly

https://www.php.net/manual/en/mysqli.prepare.php

Granted that’s how it was normally done in html 4, but things have changed a lot and this is no longer the norm. So, enforcing bad practices doesn’t help anyone learn how to do things properly.

The cart is identified by the product id, so you now have something like:
Array(
[123] => “product_id” = 123

Why would the image be in the GET array? All you actually need is the product id and quantity; everything else should be looked up when you view the cart or submit an order.

I was just trying to point something out, but you got offended. Show him the Symfony way of doing things. It may be over his head at the moment, but it builds a great (and correct) foundation to grow from.

Sponsor our Newsletter | Privacy Policy | Terms of Service