• Do any of you guys have any idea how to check what shortcodes are active or not?

    I tried with global $shortcode_tags, but I cannot get sprintf to output the structure and content of that array, and in fact array_keys or in_array seem to be ineffective.

    it is for a plugin I am working on. Any suggestion will be highly appreciated.

Viewing 3 replies - 1 through 3 (of 3 total)
  • This worked for me:

    <?php
    global $shortcode_tags;
    echo "<pre>"; print_r($shortcode_tags); echo "</pre>";
    ?>

    Resource:
    Shortcode_API

    Thread Starter icoitalyisfallingcom

    (@icoitalyisfallingcom)

    Thanks, that worked to output the array (I was using the wrong method).

    Yet I am baffled because some of the shortcodes that are supposed to be there aren’t.

    For example, nextgen shortcodes do not appear at all in the array, yet they seem to be created by the plugin with the regular add-shortcode method.

    Any idea why?

    Total guess here that those shortcodes aren’t being registered properly or only get registered under certain circumstances. Alex (authour of NextGen) is pretty active in the forums regarding that plugin so will put that plugin in the tags and maybe he can answer.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘how to list all active SHORTCODES?’ is closed to new replies.