Ready to get started?Download WordPress


WooCommerce - excelling eCommerce
Only set zip/post codes should be accepted on checkout in custom ship method. (2 posts)

  1. DanielHolm
    Posted 11 months ago #

    Hi all,

    I have a site for a client who bakes and sells pizza. When a customer adds pizzas to the cart and then tries to checkout, and checks delivery, only a array of certain zip/post codes are accepted. However, on checkout you can now add any zip/post code. The order is passed anyway and no errors.

    I've added my custom shipment class to functions.php in my theme and it looks like this: http://pastebin.com/08JvxAzg

    I've copied a lot of code from Local Delivery, which comes with WooCommerce.

    Is there another way of checking these codes and make sure that the customer has inputed anyone of them?


  2. DanielHolm
    Posted 11 months ago #

    I still haven't got this to work. What am I missing out on?


You must log in to post.

About this Plugin

About this Topic