# New payment plugin

• Posts: 25
7 years 4 months ago #22732

Hi all

If I will to develop a new payment plugin (Italian KeyClient), by one existent, doesn't is sufficient copy modifiying the names (and xml contents) from folder administrator/component/com_hikashop/extensions/plg_ ... and plugins\hikashoppayment\newplugin.. ? I tried but the plugin remains invisible; what's miss?
Thank you

Last Edit: 7 years 4 months ago by maxgag51. Reason: error in text

• Posts: 64110
7 years 4 months ago #22733

Hi,

The plugin need to be published in the joomla plugin manager. If you don't see it, it means that there is no entry for it in the jos_plugins table. That entry is normally added automatically by joomla when you install a plugin via the joomla installer.

Also, changing the names is a start but the implementation of the integration with the payment gateway is unique to each gateway. That means that you will also have to change the code to make it work with the specificities of the payment gateway.

• Posts: 25
7 years 4 months ago #22737

1. OK
2. Of course. I have all characteristics for the new payment plugin. I have attached. Could you give a look to see if, in your opinion, there are difficulties to develop?

#### File Attachment:

File Name: Note_KeyClient.txt
File Size:3 KB

##### Attachments:

• Posts: 64110
7 years 4 months ago #22738

That sounds like a standard payment gateway so there is no problems in implementing it for HikaShop.

• Posts: 25
7 years 4 months ago #22896

Hi, Nicolas
I developed new credit card plugin payment (KeyClient).
I copied from epay (similar) modifying name in keyclient; after I modified the configuration (keyclient.xml) and all php (keyclient.php, keyclient_configuration.php, keyclient_end.php) as in administrator/components/com_hikashop/extensions than in plugins/hikashoppayment.
Well, when it must open KeyClient_window (in standardwindow.js that I copied and wrote in my directories) this happens ('SI' is a my alert: first instruction of keyclient_end.php, before opening KeyClient_window) and pay_now button doesn't work and the page is in loop

Suggestions?
Massimo

##### Attachments:

• Posts: 64110
7 years 4 months ago #22897

In the txt file your provided there was no mention of a javascript file.
Looking at the txt, you should be able to just redirect to the keyclient payment gateway at the end of the checkout with a normal HTML form a two lines of javascript submitting your form.

Could you give a link to your shop so that we can try and see what could be the problem ?

• Posts: 25
7 years 4 months ago #22901

Meanwhile that I publish those are components of plugin:

#### File Attachment:

File Name: plg_hikash...ient.zip
File Size:7 KB

#### File Attachment:

File Name: standardwindow.txt
File Size:4 KB
(front-office side in: plugins\hikashoppayment)

#### File Attachment:

File Name: standardwindow.txt
File Size:4 KB
(standardwindow.js in templates\gt2)

##### Attachments:
Last Edit: 7 years 4 months ago by maxgag51. Reason: attach miss

• Posts: 64110
7 years 4 months ago #22903

You only need the payment plugin files in plugins\hikashoppayment

• Posts: 25
7 years 4 months ago #22906

www.inabox.it/gt

##### Attachments:

• Posts: 64110
7 years 4 months ago #22907

You have several problems:

First in your js file you have the line:
objForm.action = pageTracker._getLinkerUrl('<?php echo $vars["bankurl"].'?'.$vars["strECommerce"]?>');
and the line:
objPoll.src = '<?php echo $vars["bankurl"].'?'.$vars["strECommerce"]?>';

You're trying you have php executed in a js file. That's not possible.

Then, your form action URL is:
ecommerce.cim-italia.it/ecomm/Dispatcher...ZTQyMGE5ODk1ZmI%253D

As you can see you have several urls in there. That's not possible. You should urlencode all the parameters of that URL.
www.php.net/manual/en/function.urlencode.php

I see that you call open_KeyClient_window() when you click on the pay now button. Why not just submit the form like all the other payment plugins ?

• Posts: 25
7 years 3 months ago #23942

Hi Nicolas,
I have completed and tested plg_hikashoppayment_keyclient:
keyclient.php,
keyclient.xml,
keyclient_configuration.php,
keyclient_end.php;
and some add to plugin language:
en-GB.com_hikashop.ini (in language\en-GB) e en-GB.override.ini (in language\overrides)
BANK_URL="Bank url"
MERCHANT_NUMBER="Merchant number"
SECRETKEY="Secret key"
URL_BACK="Url back"

it-IT.com_hikashop.ini (in language\it-IT) e it-IT.override.ini (in language\overrides)
BANK_URL="Url della banca"
MERCHANT_NUMBER="Codice Negozio"
SECRETKEY="Chiave segreta"
URL_BACK="Url di rientro"
but I don't know how make a standard hikashop plugin payment for sharing.
Could you help me please ?

• Posts: 64110
7 years 3 months ago #23946

Hi,

You can make a zip of the files and it should be installable via the joomla installer.
For the language strings, you should use already existing translation keys. HikaShop should already have all the translation keys you want in its default translation file.

• Posts: 15
4 years 9 months ago #146276

Hi, please, can you share your plugin, if it is properly functioning?
Can I install it via Joomla installation manager?
Thank you

• Posts: 13201
4 years 9 months ago #146288

Hi,

We don't have this plugin, so you will have to wait for maxgag51.
This plugin should be installable with the joomla extension manager.

• Posts: 15
4 years 9 months ago #146307

only for virtuemart, now

• Posts: 25
4 years 9 months ago #146334

I attached the keyclient plugin
Thanks

##### Attachments:
The following user(s) said Thank You: nicolas, Jerome, AmoD, fafabone

• Posts: 4
4 years 8 months ago #150915

Hi, I'm looking for an Italian credit card payment plugin. This plugin seems helpful but I haven't understand how to register my bank count. Can you link me the bank to create my bank account?
Thank You

• Posts: 25