I wish to hide a specific checkout field based on shipping class. So if the cart contains a product with that shipping class an input fields should be hidden.

Anyone who can help me archive this?


  • It is a regular field like the address 2. If I can just add a class to the field or inject some css to hide it, it will be fine – jlock Aug 8 at 12:22

By "specific checkout field" do you mean shipping method. Because there is a free plugin which can Hide WooCommerce Shipping Method Based on Shipping Class and Shipping Zone.

If you want to hide the shipping method please let me know I will show how you can do it with the help of the above plugin.

  • No, it just a regular text field - billing address 2 - which in this case i used for another purphose :) – jlock Aug 8 at 12:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.