• Resolved optimadistributie

    (@optimadistributie)


    HI!

    My woocommerce powered website is working fine. I love the extension.
    But, in order to have the same tax for every client (us selling only in Romania), even if the client is visiting incognito or via VPN, we set up the tax based on the store location.
    All good with the tax, now having the same one for all clients; but here comes the problem:

    in the checkout page, at the billing_state field, it is completed automatically with the state of our store, so some of the clients oversee that and submit the order with the wrong state.

    I would like to find a solution for the field to be empty, and the client should not be able to finalize the order until the field is populated by the client.
    If that means for me to modify the tax section i would accept that, as long as anyone visiting the website, from anywhere, would see the same price, and have the same tax.

    Thank you!

    PS: I am willing to update to the latest wordpress and woo for this, now being a bit older.

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support EtienneP a11n

    (@etiennep)

    Hi there!

    You can add the following snippet to your theme’s functions.php file and it will make the billing state field unselected;

    //deselect checkout billing/shipping state
    add_filter( 'default_checkout_billing_state', 'change_default_checkout_state' );
    add_filter( 'default_checkout_shipping_state', 'change_default_checkout_state' );
    function change_default_checkout_state() {
        return ''; //set state code if you want to set it otherwise leave it blank.
    }

    This will remove the default state in both the billing and shipping state fields

    Thread Starter optimadistributie

    (@optimadistributie)

    worked like a charm!

    added the code with the ?Code snippets” module

    Thank you a lot!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘want for billing_state to be empty until client selects the state’ is closed to new replies.