[Skip to main content](#vessel-content)

#   Support start month/year for new payment plugin

##

- **[JohnCC](/forum/user/1259-johncc "View JohnCC's Profile")**
- [![JohnCC's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1259-johncc "View JohnCC's Profile") Topic Author
- [ Offline](/forum/user/1259-johncc)

Less More

- Posts: 2
- Thank you received: 0
-
-

15 years 8 months ago [\#8937](#8937) by [JohnCC](/forum/user/1259-johncc "View JohnCC's Profile")  *[Support start month/year for new payment plugin](/forum/4-how-to/8937-support-start-month-year-for-new-payment-plugin#8937 "Hi there,  I'm developing a payment plugin for &#96;&#96;CardSave'' in HikaShop. For it to work I need to capture the start month and end month of the credit/debit card.  I'm not sure how I need to achieve this - but I'm willing to learn. Pointing me towards an example or specific piece of documentation would be extremely helpful.  Thanks for reading.  John")* was created by *[JohnCC](/forum/user/1259-johncc "View JohnCC's Profile")*

Hi there,

I'm developing a payment plugin for &#96;&#96;CardSave'' in HikaShop.
For it to work I need to capture the start month and end month of the credit/debit card.

I'm not sure how I need to achieve this - but I'm willing to learn. Pointing me towards an example or specific piece of documentation would be extremely helpful.

Thanks for reading.

John

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg5Mzctc3VwcG9ydC1zdGFydC1tb250aC15ZWFyLWZvci1uZXctcGF5bWVudC1wbHVnaW4/dG1wbD1tYXJrZG93bg==) or [Create an account](/register) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86322
- Thank you received: 14281
-
-

15 years 8 months ago [\#8939](#8939) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: Support start month/year for new payment plugin](/forum/4-how-to/8937-support-start-month-year-for-new-payment-plugin#8939 "Hi there,  I'm developing a payment plugin for &#96;&#96;CardSave'' in HikaShop. For it to work I need to capture the start month and end month of the credit/debit card.  I'm not sure how I need to achieve this - but I'm willing to learn. Pointing me towards an example or specific piece of documentation would be extremely helpful.  Thanks for reading.  John")*

Hi,

You can look at the documentation on that page for payment plugins: [ www.hikashop.com/en/support/documentatio...r-documentation.html](http://www.hikashop.com/en/support/documentation/62-hikashop-developer-documentation.html)

If you want to capture credit card information, you should look at the credit card payment plugin included in HikaShop ( the file plugins/hikashoppayment/creditcard.php ).

In the function onPaymentDisplay, we have the line $method-&gt;ask_cc=true; to activate the credit card interface for that payment method. Also, in the __construct function, you will find the code to retrieve the credit card information that you can then use in the onAfterOrderConfirm function to proceed to the transaction.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg5Mzctc3VwcG9ydC1zdGFydC1tb250aC15ZWFyLWZvci1uZXctcGF5bWVudC1wbHVnaW4/dG1wbD1tYXJrZG93bg==) or [Create an account](/register) to join the conversation.

- **[JohnCC](/forum/user/1259-johncc "View JohnCC's Profile")**
- [![JohnCC's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1259-johncc "View JohnCC's Profile") Topic Author
- [ Offline](/forum/user/1259-johncc)

Less More

- Posts: 2
- Thank you received: 0
-
-

15 years 8 months ago -  15 years 8 months ago [\#8947](#8947) by [JohnCC](/forum/user/1259-johncc "View JohnCC's Profile")  Replied by *[JohnCC](/forum/user/1259-johncc "View JohnCC's Profile")* on topic *[Re: Support start month/year for new payment plugin](/forum/4-how-to/8937-support-start-month-year-for-new-payment-plugin#8947 "Hi there,  I'm developing a payment plugin for &#96;&#96;CardSave'' in HikaShop. For it to work I need to capture the start month and end month of the credit/debit card.  I'm not sure how I need to achieve this - but I'm willing to learn. Pointing me towards an example or specific piece of documentation would be extremely helpful.  Thanks for reading.  John")*

Hi Nicholas,

Thank-you for your response. I have already implemented a onBeforeOrderCreate() to send the credit card information to CardSave over SOAP XML. That bit seems to be working.

The proble I'm having is that I need to edit the form, to capture more data as credit cards in the UK have start dates and certain cards have issue numbers. Not all companies require them -- however CardSave do!!

Is there any way to edit the credit card form like this? (I originally started writing the plugin from the credit card plugin as a template).

Kind regards,

John

image missing http://www.hikashop.com/media/kunena/attachments/legacy/images/cardsave.PNG

- [ ![cardsave.PNG](/forum/attachment/582) ](/forum/attachment/582 "cardsave.PNG") [ ](/forum/attachment/582?download=1 "cardsave.PNG")

Last edit: 15 years 8 months ago by [JohnCC](/forum/user/1259-johncc "View JohnCC's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg5Mzctc3VwcG9ydC1zdGFydC1tb250aC15ZWFyLWZvci1uZXctcGF5bWVudC1wbHVnaW4/dG1wbD1tYXJrZG93bg==) or [Create an account](/register) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86322
- Thank you received: 14281
-
-

15 years 8 months ago [\#8948](#8948) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: Support start month/year for new payment plugin](/forum/4-how-to/8937-support-start-month-year-for-new-payment-plugin#8948 "Hi there,  I'm developing a payment plugin for &#96;&#96;CardSave'' in HikaShop. For it to work I need to capture the start month and end month of the credit/debit card.  I'm not sure how I need to achieve this - but I'm willing to learn. Pointing me towards an example or specific piece of documentation would be extremely helpful.  Thanks for reading.  John")*

Ok. You should look at the file components/com_hikashop/views/checkout/tmpl/payment.php and get the code of the credit card form which is between the
}else{
and the
}elseif(!empty($method-&gt;custom_html)){
lines and in the onPaymentDisplay, instead of using $method-&gt;ask_cc=true; to use the standard hikashop form, you can add the creditcard.js file, and set in the variable $method-&gt;custom_html the content of the form from the hikashop view. That way, you can have your own HTML form in your plugin. You can also retrieve the additional information in that same function and store it in the session for later use in the onBeforeOrderCreate function.

That way, people won't have to edit the default view so that it works with your plugin.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg5Mzctc3VwcG9ydC1zdGFydC1tb250aC15ZWFyLWZvci1uZXctcGF5bWVudC1wbHVnaW4/dG1wbD1tYXJrZG93bg==) or [Create an account](/register) to join the conversation.

- **[alphamedia](/forum/user/2021-alphamedia "View alphamedia's Profile")**
- [![alphamedia's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/2021-alphamedia "View alphamedia's Profile")
- [ Offline](/forum/user/2021-alphamedia)

Less More

- Posts: 6
- Thank you received: 0
-
-

15 years 6 months ago [\#13728](#13728) by [alphamedia](/forum/user/2021-alphamedia "View alphamedia's Profile")  Replied by *[alphamedia](/forum/user/2021-alphamedia "View alphamedia's Profile")* on topic *[Re: Support start month/year for new payment plugin](/forum/4-how-to/8937-support-start-month-year-for-new-payment-plugin#13728 "Hi there,  I'm developing a payment plugin for &#96;&#96;CardSave'' in HikaShop. For it to work I need to capture the start month and end month of the credit/debit card.  I'm not sure how I need to achieve this - but I'm willing to learn. Pointing me towards an example or specific piece of documentation would be extremely helpful.  Thanks for reading.  John")*

Hello JohnCC, were you able to implement the Cardsave module for Hiksashop. Please let me know. I have a client who has registered with Card Save and I thought I'd see if your solution was available for use. Please let me know.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzg5Mzctc3VwcG9ydC1zdGFydC1tb250aC15ZWFyLWZvci1uZXctcGF5bWVudC1wbHVnaW4/dG1wbD1tYXJrZG93bg==) or [Create an account](/register) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.147 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
