PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

conditional in conditional

  1. Hi,
    i´m using some code like this in my thank you page.
    If the user checked Newsletter, this code will be loadet in the thank you page:

    [gravityforms action="conditional" merge_tag="{newsletter.:13.1}" condition="greater_than" value="1"]<iframe src="http://url.com/?gender=HERE-IS-MY-PROBLEM&email={E-Mail:6}" width="1" height="1" frameborder="0"></iframe>
    [/gravityforms]

    Works fine... But i have troubles with the gender value.

    In my form is a dropdown with "male/female". But i need in my url a 0 for male and a 1 for female. So i have tryed to put a conditional shortcode in another. That causes errors.

    Have you any ideas for me?
    Something like:
    IF GENDER == MALE ->0 ELSE 1

    Thank you

    Posted 11 years ago on Monday March 18, 2013 | Permalink
  2. David Peralty

    Try enabling values on the dropdown and then using the merge tag for that field with :value appended on it so that it uses 1 for female and 0 for male as you can't stack conditions in Gravity Forms.

    Posted 11 years ago on Monday March 18, 2013 | Permalink
  3. Sorry, i think i don´t understand ;-)

    The problem is that i have put a shortcode in a shortcode...

    Example: This won´t work

    [gravityforms action="conditional" merge_tag="{newsletter:5}" condition="is" value="1"]
    some code

    [gravityforms action="conditional" merge_tag="{gender:2}" condition="is" value="1"]
    some code
    [/gravityforms]
    [/gravityforms]

    Posted 11 years ago on Monday March 18, 2013 | Permalink
  4. I could make a new hidden field... but also here i need a IF Else logic....

    Posted 11 years ago on Monday March 18, 2013 | Permalink
  5. Is it possible to use PHP on the thank you message? Than i coult build a little switch...

    Posted 11 years ago on Monday March 18, 2013 | Permalink
  6. David Peralty

    There is no way to do an if/else with our messages currently. WIth the 1.7 beta you could set up a bunch of conditional messages using conditional logic rather than conditional shortcodes that would let you have "Send this message if ALL of the following are true" - newsletter = 1 and gender = 1. Check out our blog for more details about the 1.7 beta - http://www.gravityhelp.com/

    Posted 11 years ago on Monday March 18, 2013 | Permalink