Page 1 of 1

shopping cart

Posted: Mon Jul 08, 2002 9:23 am
by sebamed
:?:
Hi

Well, does anyone have clue how to construct a shopping cart with mysql in the backend, that calculates subtotals and totals and has a changeable quantity?
or maybe it's better to do these kind of a calculations with javascript?

Posted: Mon Jul 08, 2002 9:28 am
by protokol
PHP is definitely the way to go. Javascript is flawed because you need a browser to have it enabled in order for it to work. This is why I think it is stupid when people do their form validation using JavaScript.

As for writing the script, you would basically store all of your products (descriptions, quantities avail., cost, etc) in the mysql database and use HTML forms to display and update the values.

You really need to look at http://www.sqlcourse.com for SQL query information, and phpcomplete.com has good PHP information.

Posted: Mon Jul 08, 2002 9:35 am
by martin
A good free ecommerce solution can be found at http://www.oscommerce.com/.
The support forum on the site will make it almost painless to set up :wink:

Posted: Mon Jul 08, 2002 10:40 am
by llimllib
if you want to do it yourself, check out this book