• Resolved anpu

    (@anpu)


    Hello Dave,

    Is it possible to use the code like the below? I’ve tried but it doesn’t work. I’m using WP version 4.6.1, perhaps that’s the reason? If not could you help me with this please. Here is what I’m trying to do:

    [time-restrict-repeat type=”daily” ontime=“06:00:00″ offtime=“06:59:59”]
    [ai_playlist id=”867″]
    [/time-restrict-repeat]
    [time-restrict-repeat-2 type=”daily” ontime=“07:00:00″ offtime=“07:59:59”]
    [ai_playlist id=”915″]
    [/time-restrict-repeat-2]
    [time-restrict-repeat-3 type=”daily” ontime=“08:00:00″ offtime=“08:59:59″]
    [ai_playlist id=”917″]
    [/time-restrict-repeat-3]
    [time-restrict-repeat-4 type=”daily” ontime=“09:00:00″ offtime=“09:59:59″]
    [ai_playlist id=”919″]
    [/time-restrict-repeat-4]
    [time-restrict-repeat-5 type=”daily” ontime=“10:00:00″ offtime=“10:59:59″]
    [ai_playlist id=”851″]
    [/time-restrict-repeat-5]
    [time-restrict-repeat-6 type=”daily” ontime=“16:00:00″ offtime=“16:59:59″]
    [ai_playlist id=”921″]
    [/time-restrict-repeat-6]
    [time-restrict-repeat-7 type=”daily” ontime=“17:00:00″ offtime=“17:59:59″]
    [ai_playlist id=”923″]
    [/time-restrict-repeat-7]
    [time-restrict-repeat-8 type=”daily” ontime=“18:00:00″ offtime=“18:59:59″]
    [ai_playlist id=”925″]
    [/time-restrict-repeat-8]
    [time-restrict-repeat-9 type=”daily” ontime=“19:00:00″ offtime=“19:59:59″]
    [ai_playlist id=”927″]
    [/time-restrict-repeat-9]
    [time-restrict-repeat-10 type=”daily” ontime=“20:00:00″ offtime=“20:59:59″]
    [ai_playlist id=”929″]
    [/time-restrict-repeat-10]

    The “[ai_playlist id=”925″]” here is for an audio player. I want it to show up at the times defined above inside a text widget on the sidebar. If I use only one of them such as:
    [time-restrict-repeat type=”daily” ontime=“06:00:00″ offtime=“06:59:59”]
    [ai_playlist id=”867″]
    [/time-restrict-repeat]
    … it works of course. But with multiple shortcodes it doesn’t.

    I’ve also tried to make this work without adding “-2”, “-3” etc… doesn’t work that way either. I can tell that the shortcodes are probably contradicting each other for some reason but I can’t figure out what’s clashing.

    Thank you very much,
    -anpu

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter anpu

    (@anpu)

    Alright… ??

    This code actually works. I’ve made the oldest mistake in the book; as you can see above, not all my quotation marks were [“] but some were [“]… that’s the reason it didn’t work. Now that I’ve made all of them [“], everything works.

    I wanted to update this thread as a caution to others who may make this mistake.

    Thread Starter anpu

    (@anpu)

    It actually works without adding “-2”, “-3” and so on, I haven’t tried it with the addition of numbers since it works without it, FYI.

    Plugin Author Dave Clements

    (@thewanderingbrit)

    Hi @anpu,

    Thanks for following up. I’m glad that you realised it was the curly quotes and not the code itself. For others having similar issues, not that the -2 and -3 variants are for when you’re nesting multiple versions of the shortcode together (there’s no such thing as -4, -5 etc.). In this case, each shortcode stands by itself, limiting each show to one hour a day.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Multiple Shortcodes’ is closed to new replies.