• Resolved pawelb84

    (@pawelb84)


    Hello,

    I have a problem with shortcode. When I am trying wrap my code in php file with <?php echo do_shortcode(‘[timed-content-rule id=”164″]’) ?>
    …my block of code…
    <?php echo do_shortcode(‘[/timed-content-rule]’) ?>
    it doesn`t work at all. Can someone tell me how to do it ?

Viewing 1 replies (of 1 total)
  • Plugin Author Arno Welzel

    (@awelzel)

    You have to pass the whole content to do_shortcode():

    $someContent = '[timed-content-rule id="164"]';
    $someContent .= '... more content ';
    $someContent .= '[/timed-content-rule]';
    echo do_shortcode($someContent);
Viewing 1 replies (of 1 total)

The topic ‘Shortcode in php file’ is closed to new replies.