WordPress.org

Support

Support » How-To and Troubleshooting » [Resolved] Shortcode string returned literally–not executed

[Resolved] Shortcode string returned literally–not executed

  • I’ve never had a use for shortcodes until now so I have to be missing something bleedingly obvious.

    Using a nextgen gallery shortcode in a page like [ album id=1 template=compact ] simply returns the literal string “[ album id=1 template=compact ]”. Same thing if I invoke it with PHP:

    <?php echo do_shortcode('[ album id=1 template=compact ]'); ?>.

    I get “[ album id=1 template=compact ]”.

    Am I missing something??

Viewing 4 replies - 1 through 4 (of 4 total)
  • Chip Bennett
    Theme Review Admin

    @chipbennett

    Try taking the space out from in between [ and album?

    ***WOW***

    Well firstly, thanks for the GREAT CATCH. This example was copied directly from the nextgen website…amazing huh?

    I guess that’s what you get for a freebie CMS plugin…

    Thanks again.

    Chip Bennett
    Theme Review Admin

    @chipbennett

    I assume the example code was written as such, in order not to have the shortcode parsed.

    I thought that’s what escape characters are for–particularly for a website documenting examples/usage of tags! (Otherwise how on earth else would a new user know that the format was incorrect?? Bizarre.)

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Resolved] Shortcode string returned literally–not executed’ is closed to new replies.