Jump to content

Magento - How to restrict Shipping Method Based on Product in the cart?

Recommended Posts

I have couple of shipping methods DHL & FedEx, if selected products exits in cart show only selected shipping method, how to archive using shopping cart pricing rule or any other way to do this?

Share this post

Link to post
Share on other sites

Without some code to look at or more details on what you are dealing with I'm at a loss to help you.  I can only imagine that your logic that handles the POST from this form examines the product that "exits" in the (shopping?) cart and then determines if the correct shipping method was selected.  If not you simply send back the form with the user's entries re-posted to it and an error message.  I suppose you could also write some JS code to do that check before the form is submitted  (maybe with an 'onsubmit' call from the submit button) and eliminate the post to the server until the input is all correct.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.