• Resolved bluantinoo

    (@bluantinoo)


    Hello,
    I’m trying to hide the VAT field if a user does not want an Invoice.
    Users decide if they want an invoice using a custom select field I added in the checkout.

    I’m using a simple jQuery function to read the value of the selected option of that field: if a user does not want an invoice, I would like to hide Company name and EU Vat field.

    While i can hide/show the company name field, it seems that I can’t on #woocommerce_eu_vat_numbe div, it’s like there’s another js overwriting my .hide() function.

    Is there a way to solve this?

    https://wordpress.org/plugins/woocommerce-eu-vat-assistant/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter bluantinoo

    (@bluantinoo)

    same problem for #woocommerce_location_self_certification div
    I can’t hide it (not even add a class) with jQuery.

    Thread Starter bluantinoo

    (@bluantinoo)

    I reached to add/remove a class to subelements of
    #woocommerce_eu_vat_numbe and #woocommerce_location_self_certification divs.
    now i can hide and show.
    Weird I could not do it to parent divs, but it works.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Hide Vat Field with JS’ is closed to new replies.