WordPress.org

Support

Support » Plugins and Hacks » Hacks » [Resolved] shortcode, cant have same plugin twice on a page

[Resolved] shortcode, cant have same plugin twice on a page

  • I have written a plugin for wordpress that uses shortcode.

    I am then using this on a page like so

    [fetch-reviews id=”1″]

    and it displays beautifully, I can also change id to “2” and get the correct display there (different users).

    however when I add both like so (on the same page)

    [fetch-reviews id=”1″]
    [fetch-reviews id=”2″]

    It displays nothing at all.

    If I add both of them like this instead

    [fetch-reviews id=”1″][/fetch-reviews]
    [fetch-reviews id=”2″][/fetch-reviews]

    the first one is displayed, but the second one is not displayed at all.
    What am I doing wrong?
    So in the above example the one for user 1 is printed. If I swap them around like so

    [fetch-reviews id=”2″][/fetch-reviews]
    [fetch-reviews id=”1″][/fetch-reviews]

    the reviews for user two is printed but nothing for user 1.

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[Resolved] shortcode, cant have same plugin twice on a page’ is closed to new replies.