Development

Using the Paypal payment plugin with the Paypal Sandbox

For developers!

The instructions provided in this document are designed for those who have experience programming Joomla extensions (plugins, modules, or components) or at least with some basic PHP skills. These instructions may have you modify your existing PHP files or database tables. You should never do this on a live site and should always have a back-up of your system prior to making any of the changes listed here. If you have an active support subscriptions you can request assistance with this process in our Support Center; however, if you need us to make custom modifications to your installation there maybe a fee for this service.

Paypal provides a way for you to test your payment processing systems with their system without putting through an actual charge. This is called the paypal 'Sandbox'.

In order to use the Paypal payment plugin you will need to have a developer account with Paypal and modify the AS Payment - Paypal plugin.

Here's what you will need to do.

Setting things up with Paypal

01Go to paypal's developer site - https://developer.paypal.com

02Select 'Test Accounts' from the Sandbox menu

03Create a test seller account
Use the links displayed next to "Create Account:" to begin creating your seller account.

You need to use the Create Manual link because it is identical to the method used to create a live account and allows you to get the codes that you will need.

04Complete the set-up process the same as a live account for paypal
Click here for instructions

Make sure that you use the Paypal Authorization Token from the sandbox when testing (it will be different than the one for your live PayPal account)

Modifying the AS Payment - Paypal plugin

01Open the plugin php file
You will fid it located in your Joomla installation here:

/plugins/ambrasubs/payment_paypal.php

FIRST save a backup copy to use when you are ready make your site live

02Change the code to point to the sandbox
Change line 321(in the section called "onREnderPaymentOptionsEdit()" change the URL from

https://www.paypal.com/cgi-bin/webscr

to

https://sandbox.paypal.com/cgi-bin/webscr


and change lines 115 & 117 (in the section called "_process()" to change the domain from

 

www.paypal.com

to

sandbox.paypal.com

and save the new plugin.

You should now be able to test your AS installation using the PayPal sandbox.

Remember to replace the modified Sandbox version with the original live version of the payment_paypal.php file when you have fully tested your site.


This development document is valid for AmbraSubscriptions version 1.5.3c+

GoogleNewsPurchase Viagra