Events Made Easy Forums How do I … Required Booking Fields in Conditional Tags

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #61434
    Anonymous
    Inactive

    Hi Franky,

    I use a standard booking form which is automatically adjusted by an event field that is filled or not while creating the event:
    [eme_if tag='#ESC_FIELD{XX}' is_empty=0]#_FIELD{YY}[/eme_if]
    with FIELD{XX} beeing the event field and FIELD{YY} a customized field to ask for extra information.

    Now my challenge:
    If the FIELD{YY} appears in the form it shall be mandatory to fill it. When I use #REQ_FIELD{YY} in the conditional tag above it unfortunately is ALWAYS required (even if the field is not visible in the form, so the user is not able to submit the form at all).

    I found out that it works when I put the FIELD{YY} not directly in my booking form but in another template (TEMPLATE{ZZ}) and include it like this:
    [eme_if tag='#ESC_FIELD{XX}' is_empty=0]#_INCLUDE_TEMPLATE{ZZ}[/eme_if]
    But I guess you have another, more elegant solution?

    Btw: When I define FIELD{YY} as a required field by default, not even this workaround helps.

    Thanks in advance
    Timo

    #61435
    Anonymous
    Inactive

    Sorry I was too fast.
    My solution does not work at all.

    #61436
    Franky
    Keymaster

    There’s an EME option made just for your use-case 🙂 See the option “Check required fields upon submit?” in the generic EME options, tab RSVP (you’ll want it to say ‘no’).

    #61437
    Anonymous
    Inactive

    Awesome!
    Thank you!

    #61438
    Franky
    Keymaster

    I’m still in doubt whether or not I should just deactivate the check upon submit by default and rely on the antispam-measures taken (honeypot field, optional captcha, wordpress nonce) to be sufficient.

Viewing 5 posts - 1 through 5 (of 5 total)
  • The forum ‘How do I …’ is closed to new topics and replies.
Scroll to Top