Shipping method restriction based on zip code

  • Posts: 46
  • Thank you received: 5
  • Hikashop Business
3 days 7 hours ago #367940

-- HikaShop version -- : 6.0.0
-- Joomla version -- : 5
-- PHP version -- : 8.3

I want to use the Manual Shipping plugin to create shipping methods for my webshop. I want this shipping method to only appear if the zip codes are between 6000 and 8000. But even though I enter 6000 and 8000 for the min. and max. zip codes in the plugin, the shipping method does not appear in the checkout if I enter e.g. 7000 in the zip code field. I use the address_post_code field for the zip code field. What am I doing wrong?

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

  • Posts: 84141
  • Thank you received: 13645
  • MODERATOR
3 days 3 hours ago #367945

Hi,

It's probable that the problem is not linked to the post code at all.
If you don't have any min and max post code in the shipping method, do you see it on your checkout ?
If not, make sure that your products have a weight or that the "Force shipping for virtual / weightless items" setting of the HikaShop configuration is turned on:
www.hikashop.com/support/documentation/5...ml#checkout_shipping
Also, check that you still have the "shipping" view in your checkout workflow.

Also, you can review the different points of the FAQ about shipping methods here:
www.hikashop.com/support/documentation/106-faq.html#ship

If you're not able to find the issue, please provide more information about the issue: URL of the shop, instructions to reproduce, screenshots of the settings of the shipping method.

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

  • Posts: 46
  • Thank you received: 5
  • Hikashop Business
2 days 15 hours ago #367954

Dear Nicolas!

Thank you very much for your help, it seems that the problem is starting to be solved. But I will describe what I am experiencing and what I would like to achieve.

1. If I specify zip code limits in the manual shipping plugin settings (min. 6000 and max. 8000), then in the checkout I can read "No shipping method found" instead of the shipping method.

2. If I enter 7000 as the zip code in the shipping address in the checkout and click the "Next" button, the shipping method is displayed. So this works, but only if the "Next" button is also present. However, the "Next" button seems inconvenient.

My question is, is it possible to make the page work without the "Next" button? Is there a solution so that if I enter the correct zip code, the shipping method is displayed immediately?

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

  • Posts: 84141
  • Thank you received: 13645
  • MODERATOR
2 days 10 hours ago #367956

Hi,

Well, before a button is pressed, the address is not sent to your website by your browser. So, it is normal that the system on the server is not able to display shipping methods restricted based on information provided in the address.
However, there are several things you can do:
- Once you have your shipping methods setup, you can turn off the "display errors" of your shipping view in the Checkout workflow of your HikaShop configuration. That way, before a shipping address is provided, the system won't display the error in the shipping methods selection area, and once the address is provided with the button below the address form, the shipping method will appear.
- You didn't provide a screenshot of your checkout settings in the HikaShop configuration, nor a link to your shop, so I can't say for sure how your checkout is setup. However, by default you have the address form, then the "next" / "register" button, then the shipping methods / payment methods selection and only then the main "next" / finish" button. There is an option in the "login" view to remove the "next" / "register" button below the address form, forcing the user to scroll down to the bottom of the page to use the main "next" / "finish" button. If you've activated that option, I understand that it is quite disconcerting for the user to see that shipping method error before clicking on the next button at the bottom as it feels the address has been taken into account and he doesn't understand clearly what will happen when he presses the main at the bottom.
- Also, you can configure your checkout to be in several steps:
www.hikashop.com/support/documentation/4...eckout-workflow.html
When you have a situation, like yours, when some parts of the checkout depends on other parts of the checkout, it makes sense to have several steps, with the depending parts in different steps. That way, you avoid this kind of confusion on the user end. Plus, with a checkout in several steps, you can display a progress bar which makes it a lot more clearer to the user where he is at and where he is going. I would recommend looking into this.

Auto submitting the not necessarily completely filled address once the zip code is provided so that the shipping methods area can be refreshed is not a solution I would recommend. This will generate error messages because some of the address required fields are not filled. And even if you add some check to only submit the address once every required address field is filled, this means the user won't be able to review his address or fill other non required fields before the interface changes. While this is fine to auto submit when it is a filter on a listing of products, or when it is an input field for a security code, you normally don't want to auto submit a whole address form for the user.

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

Time to create page: 0.065 seconds
Powered by Kunena Forum