whmcs gateway module documentation
last updated: 15th may 2009
creating a module
creating a module is a very simple process. It’s only as difficult as the api you will be connecting to. The below steps will guide you through the process.
- take the module template and rename to modulename.php
- all functions are prefixed with the filename so replace all occurrences of template_ with modulename_
- if your gateway module won’t support automated refunds, delete the _refund function (line 103)
- if a third party gateway (user leaves your site to pay) then delete the _capture function (line 57) and enter your gateway submission code into the _link function
- if a merchant gateway (payment by credit card on your site) then delete the _link function (line 14) and enter your card processing code into the _capture function
- save any changes & upload to the path modules/gateways/modulename.php
- activate and configure your gateway in setup > payment gateways
that’s it! You can now begin testing!
creating a callback file
if your gateway supports it, you can automatically mark the invoice paid with a callback script. A basic sample callback file is included in the zip with filename callback.php. For this you need to rename to your gateway to prevent any name conflicts, modify the variables to work with what your gateway returns and upload to the modules/gateways/callback folder.
یکی دقیق معنی کنه !
تا اوجایی که من خوندم فکر نکنم روی همه بانکها جواب بده !