Stock ASP Code?

Discussion in 'ASP Snips' started by BalearicJobs, Jan 19, 2007.

  1. BalearicJobs

    BalearicJobs Perch

    Hi Ladies and Gents

    Just wondered if you could help me out.

    I would like a script that allows me to update a number by email or text message? Or failing that just by an admin control panel which I could access via any browser.

    Basically I am selling some sim cards through my site via Paypal, however Paypal doesn't have a stock control option, so when I run out of stock it will continue accepting payments, which could be costly. I don't want to install a full shopping cart system on my site.

    I would like to be able to update the Stock Number on the Shop page of my website remotely as soon as I am made aware of a sale. I do this because Paypal automatically generates an email, and my email is set to come stright onto my mobile/cell phone (Nokia E61 with Push Email). This way, when I run out of stock, it will show zero immediately after I have confirmed my last sale and therefore purchasers will know that any further orders will be pre-orders.

    I hope I have expained that well enough. Is something like this possible?

    Thank you for your help! Its appreciated.
  2. tonto

    tonto Perch

    Yes there is a way to do this using PayPal's IPN (Instant Payment Notificcation.) Basically what happens is PayPal sends an HTTP response to a page of your choice that contains all of the payment information for a payment. Your page that PayPal posts to can be an ASP page that updates a database table. The database table can be a simple table with the part number and quantity on hand. Each time you receive a payment just decrement the quantity on hand by the quantity sold.

    I hope this helps.

Share This Page

JodoHost - 26,000 hosting end-users in 100 countries
Plesk Web Hosting
VPS Hosting
H-Sphere Web Hosting
Other Services