This add-on allows you to take payments with PayPoint's Lite and Professional gateways.
Please note this plugin requires CartThrob 2.0503
Tested with:
- EE2.2.2
- CarThrob 2.0503
- Download and extract the zip archive
- Place the file Cartthrob_paypoint_secpay.php in your cartthrob/payment_gateways folder
- Place the file cartthrob_paypoint_secpay_lang.php in your cartthrob/language/english folder. Feel free to translate and send back to me.
- Make a Response template (see example code below).
- Login to EE and go to your CartThrob control panel
- Click the Payments tab
- Select PayPoint.net (Secpay) from Choose your primary payment gateway
- Enter your Merchant ID
- Enter your digest password
- Select a Transaction Mode. This will need to be Live to take actual orders.
- Enter your currency code
- If you have a pro account, enter the name of your Payment template
- Select your Response template
- Specify if PayPoint should send it's own customer notification emails with Send Paypoint customer email
- Specify if PayPoint should send it's own vendor notification emails with Send Paypoint admin email
- Specify if cart contents should be sent to PayPoint with Send order items
- Now configure your shop and templates as per standard CartThrob instructions
The checkout form field names for CartThrob and PayPoint differ, but (from the point of view of this plugin) you can use either. It's probably best to use the CartThrob names however to maximise compatibility.
Please note that if you submit a PayPoint field name to the checkout, it will overwrite the CartThrob equivalent. The table below contains a full list of supported field names.
<th scope="col">PayPoint field name</th>
<th scope="col">CartThrob field name</th>
<th width="30%" scope="col">Notes</th>
<td>bill_addr_1</td>
<td>address</td>
<td> </td>
<td>bill_addr_2</td>
<td>address2</td>
<td> </td>
<td>bill_city</td>
<td>city</td>
<td> </td>
<td>bill_company</td>
<td>company</td>
<td> </td>
<td>bill_country</td>
<td>country</td>
<td> </td>
<td>bill_email</td>
<td>email_address</td>
<td> </td>
<td>bill_fax</td>
<td class="na">n/a</td>
<td class="na"> </td>
<td>bill_name</td>
<td class="na">n/a</td>
<td><em>If not provided, will be automatically generated from first and last name</em></td>
<td>bill_post_code</td>
<td>zip</td>
<td> </td>
<td>bill_state</td>
<td>state</td>
<td> </td>
<td height="32">bill_tel</td>
<td>phone</td>
<td> </td>
<td>bill_url</td>
<td class="na">n/a</td>
<td class="na"> </td>
<td class="na">n/a</td>
<td>last_name </td>
<td> </td>
<td>ship_addr_1</td>
<td>shipping_address </td>
<td> </td>
<td>ship_addr_2</td>
<td>shipping_address2</td>
<td> </td>
<td>ship_city</td>
<td>shipping_city </td>
<td> </td>
<td>ship_company</td>
<td>shipping_company</td>
<td> </td>
<td>ship_country</td>
<td>shipping_country</td>
<td> </td>
<td>ship_email</td>
<td class="na">n/a</td>
<td class="na"> </td>
<td>ship_fax</td>
<td class="na">n/a</td>
<td class="na"> </td>
<td>ship_name</td>
<td class="na">n/a</td>
<td><em>If not provided, will be automatically generated from first and last name</em></td>
<td>ship_post_code</td>
<td>shipping_zip </td>
<td> </td>
<td>ship_state</td>
<td>shipping_state </td>
<td> </td>
<td>ship_tel</td>
<td class="na">n/a</td>
<td class="na"> </td>
<td>ship_url</td>
<td class="na">n/a</td>
<td class="na"> </td>
<td class="na">n/a</td>
<td>shipping_last_name </td>
<td> </td>
This is a sample template. Available available variables are:
{if authorized}...{/if}
{if not_authorized}...{/if}
{order_id}
{error_message}
{if authorized}
# Thank you for your order
Your order has been processed and a confirmation email has been sent to you.
Your order number is: **{order_id}**, please quote this is any correspondance with us.
{/if}
{if not_authorized}
# Order Failure
{error_message}
**YOUR CREDIT CARD WAS NOT AUTHORISED.**
Your account will not be debited.
{/if}