VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: samuel fisher on September 07, 2015, 15:34:52 PM

Title: PAYMENT INTEGRATION
Post by: samuel fisher on September 07, 2015, 15:34:52 PM
I am trying to integrate a new payment system on my virtuemart store. My bank gave me an API as follows..

Create a HTML form in the referring web page that contains a few mandatory fields.

1.1 Form Creation
1.   Create a form in the location that the "Pay" button should appear
2.   Set the form's action to <URL to be provided>
3.   Set the form's method to POST
4.   Create a hidden fields shown the table below, note that only 7 fields are mandatory .i.e. product_id, amount, currency, site_redirect_url, txn_ref, hash and pay_item_id
5.   Create a submit button in the form.


I do not know how to go about this. .

I am using Joomla 2.5 and Virtuemart version 2.6.14

Any help is highly appreciated
Title: Re: PAYMENT INTEGRATION
Post by: GJC Web Design on September 07, 2015, 20:38:28 PM
You need to build a proper payment plugin to integrate with the VM checkout procees.
There are plenty bundled with the std. VM .. you use those as code examples
Title: Re: PAYMENT INTEGRATION
Post by: samuel fisher on September 10, 2015, 09:47:15 AM
Quote from: GJC Web Design on September 07, 2015, 20:38:28 PM
You need to build a proper payment plugin to integrate with the VM checkout procees.
There are plenty bundled with the std. VM .. you use those as code examples

Thank you for your reply. could you please clarify me on how to do this? i am a beginner in virtuemart. I really appreciate this.
Title: Re: PAYMENT INTEGRATION
Post by: GJC Web Design on September 10, 2015, 10:23:23 AM
If you don't have the skills then the normal approach is you employ some one to do it..  same as when the washing machine breaks..   ;)
Title: Re: PAYMENT INTEGRATION
Post by: samuel fisher on September 10, 2015, 16:16:08 PM
Quote from: GJC Web Design on September 10, 2015, 10:23:23 AM
If you don't have the skills then the normal approach is you employ some one to do it..  same as when the washing machine breaks..   ;)

That's understandable.. but I do have the willingness to learn ,as i'm in love with virtuemart and plan to use it a lot.
Title: Re: PAYMENT INTEGRATION
Post by: GJC Web Design on September 11, 2015, 00:15:28 AM
then pull apart a standard washing machine -- oops sorry.. VM payment plugin (Authorize plug is a good place to start) and see how it works

It is all standard php/Joomla coding ..
Title: Re: PAYMENT INTEGRATION
Post by: samuel fisher on September 15, 2015, 14:57:01 PM
Quote from: GJC Web Design on September 11, 2015, 00:15:28 AM
then pull apart a standard washing machine -- oops sorry.. VM payment plugin (Authorize plug is a good place to start) and see how it works

It is all standard php/Joomla coding ..

This is actually what i'm trying to learn.. Looks like you won't, can't , or don't want to help. Anyways, thanks for trying at least.
Title: Re: PAYMENT INTEGRATION
Post by: GJC Web Design on September 15, 2015, 16:08:53 PM
My hedges need cutting.. if you come round on the weekend and help, I'll help you do your job.. fairs fair..  :)
Title: Re: PAYMENT INTEGRATION
Post by: jenkinhill on September 15, 2015, 17:47:50 PM
Or there are plenty of PHP courses, eg http://www.w3schools.com/php/ is but one option.
Title: Re: PAYMENT INTEGRATION
Post by: balai on September 16, 2015, 12:06:20 PM
A good start is to try to understand the structure of the joomla plugins
Have a look here
https://docs.joomla.org/J3.x:Creating_a_Plugin_for_Joomla

Plugins follow the observer pattern. In short during the runtime a function (event) triggers another function in each of the plugins (observer) in the same category (e.g vmcustom).
Hence plugins in the same category (e.g. vmcustom) should have the same functions.

So in your case a good start is to open an existing payment plugin and copy it's functions. Then just change the logic inside the functions to make it fit your needs.

p.s. Guys let's calm down.
I suppose that our participation to the forums is done by good intention at our free time. If someone has not the time to answer why should he do that?