Support » Plugin: Conditional Fields for Contact Form 7 » Hiding Dropdown Fields

  • Resolved moliver27

    (@moliver27)


    I’d like to hide a field based on the selection of separate field.
    Basically, I’d like to only display the “State” dropdown if United States is selected from the “Country” dropdown.

    I have downloaded and installed Contact Form 7 Conditional Fields but I’m having difficulty with the coding and setting the conditional fields.

    Here is a link to a screenshot: screenshot

    Or do I have to download the Modules plug-in and hide the fields in the email? Our forms are getting hung up transferring to Salesforce because the “State” field isn’t selected if the “Country” field is selected.

    Thank You!

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

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Jules Colle

    (@jules-colle)

    I’m not quite clear on your question. Do you need help hiding the State field until United States is selected in the Country dropdown?

    moliver27

    (@moliver27)

    Thank you for your response!

    I’d like to hide the state field if the selected country is NOT the United States.

    People our filling out the contact form and selecting a random state if they’re from a country outside of the United States. Our leads in Salesforce are getting rejected because the fields align.

    I hope that makes sense? Thanks!!

    Plugin Author Jules Colle

    (@jules-colle)

    This is pretty basic. Are you just asking if it’s possible? Cause if that is your question, then my answer is “yes it’s possible.” Did you check out the tutorial?
    https://conditional-fields-cf7.bdwm.be/conditional-fields-for-contact-form-7-tutorial/

    • This reply was modified 4 weeks ago by  Jules Colle.

    I did use the tutorial with not much luck. Unfortunately, I deleted what I had or I’d send it over to you.

    I guess I’ll give it another shot. Thanks,

    Plugin Author Jules Colle

    (@jules-colle)

    good luck! It’s really much simpler than you think imo. All you would need it so wrap the state field in a group and than add a condition like this:

    show group if country equals Unites Stated

    Thanks. I’m still having some trouble: screenshot

    I believe I have the grouping correct. Should the text string be coded differently? [group group-200 clear_on_hide]

    Any thoughts?

    Thanks!

    Plugin Author Jules Colle

    (@jules-colle)

    Just put United States instead of United States|US

Viewing 7 replies - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.