Scriptabulous!

Back

vsSellOut

A little while ago I won a whole bunch of copies of a DVD. I needed a little script to help me sell them so that I didn't have to babysit the site when my inventory was gone. I knew that Paypal could take care of gathering the shipping information and notifying me when a sale was made, so I didn't try to reinvent the wheel. So I wrote this little script. A customer clicks on a link, and then if there is still invesntory left, they are forwarded to Paypal. Everytime someone buys a product, Paypal notifies the script, and the script records another transaction. If all of the inventory has been sold, the customer is taken to a "Sorry, all gone" message instead of Paypal.

Download this script