Couffin: Yet another PHP shopping basket
You might be thinking, why on earth does the world need another PHP shopping cart? I certainly would agree with you. Several months ago I was faced with the task of helping my wife switch out of PayPal’s shopping cart. I initially thought that there must be thousands of shopping cart already written, and quickly realized that there were. Unfortunately, they all seemed to be way too complex for a simple site that needed to sell a dozen products and wanted to maintain a tight control on the look and feel. I checked out Zen Cart which I really liked initially. It offers lots of features, but overall is more of a complete store front as opposed to a simple cart.
I only needed a cart that would gather few products, capture the customer information and hand off the transaction to a secure credit card processor such as charge.com.
After a while, I decided that this would be a good opportunity to play around with PHP and CSS and wrote a cart of my own. I named it “Couffin” after a French word for a sturdy yet simple basket made of woven straws, often used to shop at open air markets in Provence. It’s pronounced “ku-fn”.
If you are looking for a simple set of PHP scripts to get a jump start on your next shopping cart project, hopefully you’ll find Couffin useful. Download the source code or see it in action.
Like





This absolutely GREAT ! You made my day (and much to come). Searching for something like this since more than two days now. Wait… i am gonna scream it outside now: YESSSSSSSSSSSSS :-) After searching hotscripts.com and others, crawling through hundreds of shopping cart and e-commerce scripts i found a javascript NOP free cart script. But i would love to find something similar in a PHP-version. I needed something very tiny, transparent, fast to use and build for a tiny job (just some photo’s). Merci beaucoup! Oh, nice pictures too, this brings some human touch to this site too.
First of all thank you for this. It’s helped me alot in my quest to create a simple shopping basket. Anyhoo, I live in england and so everything is different. E.G states etc. I’ve managed to change the states and some other stuff. But my main problem is the validation… as nice as it is to have it, phone numbers and zip codes are different lengths here. So where do you keep your validation rules? Thanks again.
-John
Err nevermind, found ‘em.
Hi, This PHP code is excellent can we use it?
Hi,
Im after some help please regarding your excellent PHP shopping basket code.
Is it possible to dynamically pass the basket total to PAYPAL either via a paypal button or via the process order link?
I notice you had a payment process page but I didn’t really understand it, im good with ASP but a novice in PHP.
Any help would be very grateful
is it possible to use database for the products
If anyone wnts to now how to integrate mysql with this super sinple shopping cart should email me admin@learntotal.com
I read that the cart can only take up 12 items, when it is used with MYSQL will it still be limited 12 items?
http://www.mybt.co.uk
hi, your shopping cart is awesome, but when i tried to implement it in my host it tells me this error..am i doing something wrong?
Parse error: syntax error, unexpected $end in /home/stud/s3243181/.HTMLinfo/mini/index.php on line 67
hi, when i click “Check Out” script – no working? why? please help.
HI jhon, I am getting the same error. Did you find a solution? Like Richard I have many years experience with ASP amd ASP.Net, but am completely new to PHP. I am just fixing up a site for friend and really could do with some help.
Thanks
Hi Bethel,
I tried to send you an email regarding the MySQL update, but the email came back as unknown domain, can you let me have a new email address.
Thanks