[ic] Creating Payment Modules

Lyn St George interchange-users@icdevgroup.org
Mon May 26 10:05:01 2003


On Mon, 26 May 2003 17:48:24 +1200, Joedi Hiscox wrote:

>I am using Interchange 4.9.3 and need to create 2 custom payment modules.
>They are pretty basic ones one for Direct Credit Payment and One for Cheque
>Payment.  I only require people ordering from my site to enter their address
>and phone details I dont need credit card numbers or anything like that.

I'm half way through one for Datacash here in the UK which does Direct Debit, 
Direct Credit, and Cheque. I forget the terminology back home in NZ but
here a Direct Debit is where the customer gives permission for his 
account to be debited directly and the funds credited to the seller's 
account. Is this what you refer to as 'direct credit'? (here, DCredit means
that the merchant who administers the shop/payment module can credit
funds to the bank account of the customer or any chosen recipient, and
also credit funds to a credit card 'collection' account).

>I would like the confirmation email sent to them to include my companies
>bank account details (If they order by direct credit) or postal details (If
>they order by cheque)
>
>There is an online check option but I dont want to use this as it doesnt
>work in NZ.
>
>Where can I find these modules to create new ones and what do I need to do
>to add these payment methods.  What pages do I have to edit.

Do you want to do both of these off-line? If so, then you don't need a 
payment module at all, as these modules are only there to allow 
real-time payment on-line. To set up the cheque option, just allow it
in 'variable.txt' and add your postal details to etc/receipt.html. To set
up the debit/credit option for off-line use, make a new mv_order_profile
modelled on, say, the existing 'online_cheque' one. In both of the included
*_browser_payment files (in include/checkout) copy the existing 
[elsif value mv_order_profile eq online_cheque] stuff [/elsif] and call
it direct_credit instead. Edit all the fields to suit, adding new ones as 
appropriate. In etc/receipt.html, add your bank details wrapped with
[if value mv_order_profile eq direct_credit] ... [/if]. Should to the job.

If you want to do the 'direct credit' stuff in realtime, then mail me off list.
(the Datacash module will be donated to the IC dev team when it's
finished, but at the moment it's not)


>Sorry if it sounds dumb im new to interchange and would appreciate any help
>I can get

No problem being new to IC. All that matters is that you send in clear and 
well researched questions, which you have. 

>Thanks
>Joedi

HTH

-
Cheers
Lyn St George
+---------------------------------------------------------------------------------
+ http://www.zolotek.net .. eCommerce hosting, consulting
+ http://www.os2docs.org .. some 'How To' stuff ...
+----------------------------------------------------------------------------------