Custom shipping plugin

  • Posts: 11
  • Thank you received: 0
  • Hikashop Business
9 years 3 months ago #210409

-- HikaShop version -- : 2.5.0 Business
-- Joomla version -- : 3.4.3
-- PHP version -- : 5.5
-- Browser(s) name and version -- : Firefox 39.0

Hi,

I need to create a custom shipping plugin with the following properties:

- 4 shipping zones
- base price for every x items and individual price for other items, (example if x = 6, shipping for 8 products would be 2xbase + 6xindividual, shipping for 5 products would be 1xbase + 4xindividual)
- base price, x number of items and individual price are dependent on the value selected in a custom field and upon the shipping zone

Is this possible within hikashop or do I need to create a custom shipping plugin? If so, which files do I need to look at?

Kind Regards

Jaz

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
9 years 3 months ago #210411

Hi,

That would require a custom shipping plugin.
You can base yourself on the plugins/hikashopshipping/manual/ plugin to create a new shipping plugin.
You'll see that it almost doesn't have any code as it extends from the HikaShopShippingPlugin class that you'll find in the administrator/components/com_hikashop/helpers/helper.php

So in your plugin, you can override the methods of that HikaShopShippingPlugin class in order to set the price you want for it based on the content of the cart.
You'll want to override the onShippingDisplay method in your plugin.

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

Time to create page: 0.057 seconds
Powered by Kunena Forum