IPN PayPal PHP Script


This set of script files allows you to sell downloadable goods safely and automatically.
Required are:

  • PayPal business account
  • Hosted web space account
  • PHP scripting server on same hosted server
  • MySQL database on same hosted server
  • Enabled IPN and set RETURN in PayPal preferences to the script file
  • Basic Knowledge of PHP, MYSQL and FTP

Once a purchase is made the transaction is verified by script thru checking:

  • Item Price,
  • Past Transaction IDs,
  • Payer Validity,
  • Validity of YOUR email as the seller,
  • Payment status (Completed),
  • return of VALID from PayPal after post.

Once all is OK:

  • Your customer gets an email with password and login link,
  • You will get order confirmation email with the same link to check download,
  • Sales and users are recorded in MySQL
  • Once costumer has logged in they can download particular Item# they have paid for unlimited amount of times.  This can be limited by editing PHP code.

If the payment is other than "Completed":

  • You and the costumer will receive emails notifying you of the payment status
  • If paying by eCheck the download login will be sent to costumer when payment clears
  • You will be notified by cleared payment in same fashion as the Completed order

If the validity check(s) failed:

  • You will be notified of type of problem
  • Potential fraudster will get an email warning of "activity logged", you can tailor the message any way you want it but keep in mind that PayPal error could have caused invalidity response.

All data is logged in a log file in the same server directory as the script.  You can see how many times a file has been downloaded by each person by viewing users database table.  

You must do the first download of each product as the logs need to be auto-created and this dumps errors on the screen.




Select Test:

Clicking the button above will allow you to see the script in action.  You can use standard or encrypted paypal buttons as well. The transaction cost is 1 penny.


Download only price $7.95

Tech Support for the Script

While I will gladly help you with any potential problems, I assume that you know what PHP, MySQL, Paypal and FTP Hosting access are and no tutoring is required.  There is a vast volume of information on these topics online.




Send mail to Webmaster with questions or comments about this web site.
Copyright 2005 Jouster
Last modified: 10/20/08