Case Study
PowerTranz Payment Gateway Integration for a WordPress Church Donation Website
The project involved developing a WordPress donation solution for a church that wanted to collect contributions from its members through its website. The main requirement was to connect the donation form with the PowerTranz Hosted Payment Page, allowing members to submit their information and complete payments through the payment provider. The solution needed to support a straightforward donation process, handle payment responses correctly, and provide a clear separation between the church website and sensitive card information.
The Challenge
The Starting Point
The church needed more than a standard contact form. It required a donation workflow that connected member information with an external payment gateway.
The main requirements included:
A donation form to collect the member’s name, email address, church name, member ID, and donation amount.
Integration with the PowerTranz Hosted Payment Page.
Support for credit and debit card transactions.
Separate sandbox and live payment configurations.
Recurring donation functionality, subject to the payment provider’s supported features and merchant configuration.
Payment response handling and clear confirmation messages.
Server-side validation and secure handling of payment requests.
Testing of the complete donation process before production use.
A key technical requirement was to ensure that the website could initiate a payment, redirect the member to the hosted payment page, and process the returned transaction status without treating a redirect alone as proof of a successful payment.
Objectives
Key Goals for the Project
The objective was to give the church a convenient way to collect donations through its WordPress website while using PowerTranz to process card payments.
The plugin was intended to connect donor details with the payment process, support multiple donation categories, and provide a clear checkout experience. Keeping the functionality in a dedicated plugin also made it easier to maintain the integration separately from the website's theme.
Our Approach
A Structured and Collaborative Process
How I Built the WordPress Plugin
Custom Donation Form
I developed a donation form tailored to the church's requirements, allowing members to submit their name, email address, church name, member ID, and donation amount. I used a shortcode-based approach so the form could be added to a WordPress page without modifying the theme. The form also validates required information before moving to the payment stage.
PowerTranz Payment Integration
I connected the WordPress donation workflow with the PowerTranz Hosted Payment Page (HPP). The plugin prepares the required payment request and directs donors to the provider's hosted checkout, where they enter their card details. This keeps card entry outside the WordPress form and provides a clear separation between donation collection and payment processing.
Payment Request Validation
I structured the payment process to validate donor information and donation amounts on the server before sending a request to PowerTranz. The plugin needs to use the correct merchant configuration, transaction details, and currency. This helps prevent invalid requests and ensures that payment processing does not rely solely on values submitted through the browser.
Checkout and Transaction Handling
The checkout workflow connects form submission, payment initiation, hosted checkout, and transaction response handling. After the donor completes or cancels a payment, the website must determine the actual transaction status before displaying a confirmation message. This helps prevent failed, cancelled, or incomplete transactions from being reported as successful donations.
Sandbox and Live Configuration
The integration uses separate configurations for sandbox testing and production processing. The sandbox environment allows the payment request, checkout redirection, and transaction responses to be checked before live payments are enabled. Production credentials and gateway endpoints must remain separate from test settings, with sensitive credentials stored securely on the server.
Recurring Donation Support
Recurring donations were included in the church's requirements alongside standard card payments. The integration needs to follow the recurring-payment options supported by PowerTranz and the merchant account, including the required authorization and subsequent transaction handling. This feature requires separate testing because recurring payments involve additional steps beyond a one-time donation.
Security and Testing
The development approach accounts for server-side validation, protected gateway credentials, HTTPS, and appropriate error handling. Testing covers form validation, payment request formatting, hosted checkout, transaction responses, and failed payment scenarios. Recurring payments and live processing should be reported as completed only after their respective workflows have been verified.
Scope
What We Delivered
The scope covered the development of a custom WordPress donation plugin, the collection and validation of donor information, integration with the PowerTranz Hosted Payment Page, payment response handling, and the configuration needed for sandbox and live processing.
The requirements also included credit and debit card payments, recurring donations, end-to-end transaction testing, and secure handling of payment requests and responses.
Very happy with how this project went. Communication was great throughout, and we delivered a project that exceeded the client's expectations while staying within budget and meeting the deadline. Highly recommended. You won't be disappointed.
Outcome
Results
The project centered on a dedicated WordPress plugin for the church's online donation workflow. The design brought together donor information, donation categories, currency selection, and the planned PowerTranz hosted checkout process.
Keeping the payment integration separate from the website theme provides a clearer structure for ongoing maintenance and future changes. Hosted checkout also keeps the card-entry step with the payment provider rather than placing card fields directly on the church website.
The final production outcome depends on the features that were implemented and verified, including live transaction processing and recurring donations.