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.

Nestled shortcodes will not work

  1. I have a shortcode which display a DIV with some properties.
    When I combine my shortcode with gravityform shortcode the gravityform wont be processed but my shortcode will. Gravityform shortcode will be displayed like " [gravityform id="1" ....... ] "

    I will type following in my page;
    [my-shortcode]
    [gravityform id="1" ....... ]
    [/my-shortcode]

    Maybe Gravityform does not support this???h

    Posted 12 years ago on Sunday March 11, 2012 | Permalink
  2. It's not necessarily a Gravity Forms issue.. it could be how your other (parent) shortcode is built. Generally, nesting shortcodes isn't reliable.

    If all your parent shortcode is doing is "displaying a div with some properties" then why don't you simply write the div markup out around your form shortcode?

    Posted 12 years ago on Monday March 12, 2012 | Permalink
  3. Thanks for your answer.

    A shortcode would be a much userfriendly for normal users instead of typing <div class="foo">Lorem ipsum</div>
    And with my shortcode I'll also have the possibility to have some params to get div with rounded borders, borders, colors etc.

    I will have one more look why this doesn't work,
    [my-shortcode]
    [gravityform id="1" ....... ]
    [/my-shortcode]

    Posted 12 years ago on Monday March 12, 2012 | Permalink
  4. Yeah, the parent shortcode needs to support the "do_shortcode" functionality.. to allow elements inside that shortcode to process their own shortcodes. You'll want to approach your theme developer and see if they can enable that for you.

    Posted 12 years ago on Monday March 12, 2012 | Permalink
  5. That solved the problem.
    Thanks!

    Posted 12 years ago on Wednesday March 14, 2012 | Permalink
  6. You are welcome sir. Glad that helped out. Enjoy the beautiful day.

    Posted 12 years ago on Wednesday March 14, 2012 | Permalink

This topic has been resolved and has been closed to new replies.