Jump to content

Building a shopping cart


davidf85

Recommended Posts

I am building a shopping cart with PHP and working with a tutorial

(http://jameshamilton.eu/content/simple-php-shopping-cart-tutorial)

 

I am putting together the cart and there is some coding

$sql = sprintf("SELECT name, description, price FROM php_shop_products WHERE id = %d;",

$product_id);

That i do not understand. Here it is "WHERE id = %d;"

I have never seen this before and am wondering what it means or how to work with this syntax

Link to comment
https://forums.phpfreaks.com/topic/257331-building-a-shopping-cart/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.