- Posts: 257
- Thank you received: 34
PaymentPlugin - Fields & recuriing status
- Calum
- Topic Author
- Offline
- Elite Member
-
1. How / where are things like the Credit Card Number defined as fields to display for the plugin? More specifically I want to collect a bank account sort code and bank account number. Like Credit Card Details I don't want these in my database - I want to pass them straight through to the Payment Gateway. I'm guessing thats how GoCardless is already configured? So what do I put where to get some fields!
2. My first draft of the processor says its not recurring - but I can't find where that's set either..
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
1. About this question, at the moment, Membership Pro only supports two types of payment plugins :
- Credit card base payment plugin which allows subscribers to enter creditcard information directly on your site for processing payment. For these kind of payment plugins, the constructor method looks like this:
(Note 'type' = 1 in the config tell Membership Pro that it is credit card based payment plugin, so when subscribers choose the method, credit card information will be displayed...)
- Redirect base payment plugin. For these kind of payment plugins, users will be redirected to payment gateway for processing payment (for example, PayPal). For this kind of payment plugin, the constructor has looks like this:
If your custom payment plugin need more input, you will have to add these fields to the subscription form manually (components/com_osmembership/view/register/tmpl/default.php)
2. For supporting recurring subscription, at the moment, it is controlled via a field in database. Look at #__osmembership_plugins table, find the record related to your payment plugin, set support_recurring to 1 and it will be recurring payment plugin (you would have to implement the code to process recurring payment - sorry, haven't had a documentation for that part yet)
Tuan
Please Log in or Create an account to join the conversation.
- PhoenixUK
- Offline
- Elite Member
-
- Posts: 236
- Thank you received: 21
Calum wrote: 2 questions that I suspect you just know but I can't quite figure out...
1. How / where are things like the Credit Card Number defined as fields to display for the plugin? More specifically I want to collect a bank account sort code and bank account number. Like Credit Card Details I don't want these in my database - I want to pass them straight through to the Payment Gateway. I'm guessing thats how GoCardless is already configured? So what do I put where to get some fields!
2. My first draft of the processor says its not recurring - but I can't find where that's set either..
Calum,
I hope you don't mind me jumping in here, I noticed the thread and when reading it thought I'd ask - are you specifically after the 'Recurring' GoCardless Direct Debit payment plugin by any chance, or have I misread your post?
I only ask, as I had a 3rd party developer to further develop Tuan's original non recurring GoCardless Payment plugin and now have it in use on my test site that I'm close to launching, working a treat and all linked up to my GoCardless Account, working nicely with Recurring Direct Debit payments etc.

If I'm mistaken, my apologies.
Regards,
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
Would it be OK if I give him your contact so that you can give him the payment plugin (which support recurring payment) - for a small fee I guess as I don't think he could afford to pay much
Please let me know
Tuan
Please Log in or Create an account to join the conversation.
- PhoenixUK
- Offline
- Elite Member
-
- Posts: 236
- Thank you received: 21
Tuan Pham Ngoc wrote: I have one customers need recurring payment with GoCardless, too
Would it be OK if I give him your contact so that you can give him the payment plugin (which support recurring payment) - for a small fee I guess as I don't think he could afford to pay much
Please let me know
Tuan
Tuan,
I believe I know who you mean, as he's already contacted me by email and I have replied to him. In the meantime, while I'm waiting for him to reply, can you and I discuss privately both that recurring payment plugin and the expansion of the membership pro's notification system, which is a plugin that places a notification tab within any created plan and allows for;
Use syntax tags for all of the OSMembership fields.
{field_name} is the syntax to use in the email text.
I sought it, as I need to notify suppliers of specific subscriber's sign-up or data capture information, where I can't send everything that Membership Pro gathers from a subscription plan to said suppliers; due to certain information may not adhere to various western data protection laws etc. This now gives me this ability and is a real positive addition for some I'm sure.
I'm open to providing these for the Membership Pro community but need to run something past you first.
Chat Soon.
Please Log in or Create an account to join the conversation.
- Calum
- Topic Author
- Offline
- Elite Member
-
- Posts: 257
- Thank you received: 34
So if I was to use type=2 I could create a new type of fields? What is the likelihood of core component using type=2 in the future? (I will of course share the code back so it could go in core but no guarantee you'd want it!)Tuan Pham Ngoc wrote:
(Note 'type' = 1 in the config tell Membership Pro that it is credit card based payment plugin, so when subscribers choose the method, credit card information will be displayed...)Code:public function __construct($params, $config = array('type' => 1))
Would be easier! But their payment form seems to let too many variables be changed (i.e. first payment date)- Redirect base payment plugin. For these kind of payment plugins, users will be redirected to payment gateway for processing payment (for example, PayPal). For this kind of payment plugin, the constructor has looks like this:
public function os_paypal($params, $config = array())
Aha - was assuming it'd be a configuration param on the plugin!#__osmembership_plugins table, find the record related to your payment plugin, set support_recurring to 1 and it will be recurring payment plugin (you would have to implement the code to process recurring payment - sorry, haven't had a documentation for that part yet)
Fully aware I'll need code to handle the recurrence. Oddly this gateway doesn't send confirmation messages so I actually will need a system plugin that uses a daily cron trigger that queries their database daily and then triggers the payment update! Nothing is ever simple!
Please Log in or Create an account to join the conversation.
- Calum
- Topic Author
- Offline
- Elite Member
-
- Posts: 257
- Thank you received: 34
Are you entering Sort Code and Bank Account on GC's website via a redirect or on your own site and passing it over via an SSL certificate?
Please Log in or Create an account to join the conversation.
- PhoenixUK
- Offline
- Elite Member
-
- Posts: 236
- Thank you received: 21
Calum wrote: PheonixUK - you are very welcome to jump in. I'm not using GoCardless. (that'd be too easy!).
Are you entering Sort Code and Bank Account on GC's website via a redirect or on your own site and passing it over via an SSL certificate?
Hi Calum,
It does seem you're working on something much more specific. I essentially took Tuan's MembershipPro GoCardless payment plugin but Tuan hadn't the time to activate / implement GoCardless's main feature, which is Recurring Direct Debit linked to Subscription Plans in one's MembershipPro component.
Therefore, as soon as somebody chooses the Direct Debit payment option within one of my plans (Also offer Stripe for Card payments but a majority of my target audience will feel Direct Debit is much safer, which it really is), they're then taken to my businesses GoCardless payment page which is via their API and hosted on their server not mine. Then a client can then enter their businesses bank account and sort code, generating the legal mandate and it's subsequent agreement. It's seamless and so simple.
developer.gocardless.com/2015-07-06/#cor...points-subscriptions
(Their Pro features gocardless.com/pro/#overview which one has much more control over of payment pages and so forth)
I'm only using the basic GoCardless version but in time when numbers require it, I will upgrade the payment plugin to include / work with their 'Pro' version.
Probably not a fit for your requirements but it was worth mentioning on the off chance.
Regards,
Please Log in or Create an account to join the conversation.
- Calum
- Topic Author
- Offline
- Elite Member
-
- Posts: 257
- Thank you received: 34
Please Log in or Create an account to join the conversation.
- PhoenixUK
- Offline
- Elite Member
-
- Posts: 236
- Thank you received: 21

Please Log in or Create an account to join the conversation.
Support
Documentation
Information
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.