Plugin - eWAY (Create custom order forms)
The RSForm!Pro eWAY Payment Integration Plugin allows you to add a new payment method to the existing Payment Package of RSForm!Pro.
Downloading and Installing the plugin
You can download the plugin by logging with your purchase user, then head to Downloads > My Downloads > RSForm!Pro - view all plugins and modules > RSForm!Pro Files > Plugins > "eWAY Plugin for Joomla! 3.0".
In the backend of your Joomla! installation go to the Extensions > Install/Uninstall page, and install the plugin.Next thing is to publish the plugin, to do this go to Extensions > Plug-in Manager, search for the "RSForm! Pro - eWAY" plugin and publish it.
Configuring the plugin
The integration with eWAY requires specific parameters to be added in the Components >> RSForm!Pro >> Configuration >> eWAY tab:
- eWAY API key: fill in your eWAY API Key, for more information try referring to eWAY documentation
- eWAY API password: fill in your eWAY API password, for more information try referring to eWAY documentation
- Live Mode: Yes / No - set to No in order to enable the testing mode
How to use the eWAY Payment plugin
After configuring the eWAY parameters from Components >> RSForm!Pro >> Configuration >> eWAY tab, there are some additional steps that needs to be taken in order the payment process to work properly:
Making sure the form is sent to the payment processor
The payment details will only be sent to the eWAY payment processor if the user selects eWAY from the "Choose Payment" field before submitting the form.
"Choose Payment" field is used in order to allow the users to choose their payment method. It displays the payment methods added to the form in either a Dropdown or Radio Group. It can be shown on the form (allowing the user to select his preferred payment method) or not (forcing the user to pay using the default payment method).
If you are using a single payment method and you need to hide the Choose payment field, this can be achieved by editing the field and setting to "No" the "Show in front-end?" option within the "Attributes" tab.
In order the eWAY payment method to be available within the Choose payment dropdown/radio group, the eWAY field needs to be added in form.
In order to receive funds using RSForm!Pro and eWAY payment plugin, your form needs to include a cost. In order to add costs to your form you can use any of the following fields:
- Single Product - Adds a single product to the form. For this type of field you can set up a caption, description and a price.
- Multiple Products - Adds the ability to display multiple products to be purchased either in a Dropdown or a Checkbox. Its items need to be specified in the following manner: price | label (ex: 15 | T-shirt)
- Donation - Allows the user to type in the amount to be paid inside a standard Textbox.
- Total - This field is used alongside the Donation, Single and Multiple Products fields. It calculates the total price to be paid.
Mapping form information to eWAY for card processing
1. In order to collect the user's card information, the following fields needs to be added in the form:
- Card Holder - a textbox field used in order the user to fill in the owner of the card
- Card Number - a textbox field used in order the user to fill in the credit card number
- Expiration Month - month dropdown list. Please note that the values for the Month field would have to be in the 'MM' format. (eg. 01, 02, 03).
- Expiration Year - year dropdown list starting with the current year. Please note that the values for the Year field would have to be in the 'YY' format.(eg. 16, 17)
- Card Security Code(CSC) - a textbox field used in order the user to fill in the credit card security code
2. In order to map or link the fields between the RSForm!Pro form and eWAY:
- Head to Components > RSForm!Pro > Manage Forms > Select your form > Properties > eWAY Configuration
- Select the RSForm!Pro fields corresponding to eWAY
Submitting the order form
When the order form is submitted the following actions are taking place:
- 1. The payment details are sent to eWAY
- 2. Until the transaction is processed by eWAY a loading message is displayed
- 3. After eWAY has been successfully processed the transaction, the user will be redirected to the form page and the "Thank you message" will be displayed
Modifying eWay vars through Scripts called after form has been processed
This process is similar to the already existing example regarding the PayPal parameters control. First you will need to get a new instance of the eWay object, this is done with:
$payeway = RSFormProEway::getInstance();
After this is done you will be able to override the parameters sent to eWay using the following syntax:
The above example will change the invoice number sent to the payment processor (instead of 513456 your can use your custom variable to dynamically send an invoice number). For a more detailed list of parameters available in the API you can check the official eWay variables.
3 persons found this article helpful.