Adding a Payment Method

  • Posts: 108
  • Thank you received: 2
12 years 9 months ago #48012

Hello again.
I recently needed to create a new method (or customize other), but i want to create one that will not be deleted or rollbacked after each Hikashop update.
My idea was to create a new method and customize it how i want.

I just want to know what i need to do to add a new payment plugin?
I add a new folder at: HOME/administrator/components/com_hikashop/extensions and HOME/plugins/hikashoppayment. and configured the xmls, tho still is not showing at the back-end payment methods.

Any advices?

NOTE: if is there a way to download a zip of a plugin payment, that will be great.

Last edit: 12 years 9 months ago by bars92.

Please Log in or Create an account to join the conversation.

  • Posts: 83103
  • Thank you received: 13418
  • MODERATOR
12 years 9 months ago #48079

Only HOME/plugins/hikashoppayment is used.
Also, you need to zip the files of the plugin and install the package via the joomla installer.

Please Log in or Create an account to join the conversation.

  • Posts: 108
  • Thank you received: 2
12 years 8 months ago #48138

Good it worked, i copied an existing payment method and changed is params and name. Although now when i try to go to back-end payment configuration it displays an error:

Order status
Fatal error: Call to a member function display() on a non-object in ...

I need this params because it defines the types of order status.
What may be the caus of that?

Please Log in or Create an account to join the conversation.

  • Posts: 83103
  • Thank you received: 13418
  • MODERATOR
12 years 8 months ago #48147

Please give the rest of the error message

Please Log in or Create an account to join the conversation.

  • Posts: 108
  • Thank you received: 2
12 years 8 months ago #48158

that all.. the rest is location.

Fatal error: Call to a member function display() on a non-object in HOME/plugins/hikashoppayment/pelecard/pelecard_configuration.php on line 18

The line 18 is:

<?php echo $this->data->display("data[payment][payment_params][order_status]",@$this->element->payment_params->order_status); ?>

Last edit: 12 years 8 months ago by bars92.

Please Log in or Create an account to join the conversation.

  • Posts: 83103
  • Thank you received: 13418
  • MODERATOR
12 years 8 months ago #48166

That means that in the function onPaymentConfiguration of your plugin, you don't have the lines:
$this->category = hikashop_get('type.categorysub');
$this->category->type = 'status';

like all the others payment plugins.

Please Log in or Create an account to join the conversation.

  • Posts: 108
  • Thank you received: 2
12 years 8 months ago #48816

OK i found out what was the problem after adding those lines.

thank you again.

Please Log in or Create an account to join the conversation.

Time to create page: 0.070 seconds
Powered by Kunena Forum