Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • дедЕгор
    Participant

    Hello comrades!

    The shortcode does not work in the “TG: Product Slider” widget of the “eStore” theme. Shows only text [sc name="name" ]

    Tell me friends, what should I do to make the shortcodes work?

    Thank you my friends!

    Hi,

    It seems the widget is not “executing” the shortcode. It is printing the shortcode as is.

    Can you please check with “TG: Product slider” developer to “execute” shortcodes in their widget ?

    This applies not only to shortcoder but any shortcode.

    Thanks,
    Aakash

    дедЕгор
    Participant

    Hi!

    I solved this problem myself.

    In the widget code, the place where the shortcode does not work is called like this: <div class="slider-content"><?php the_excerpt(); ?></div>

    that’s why I added the line add_filter( 'the_excerpt', 'do_shortcode'); to functions.php and it worked!

    Excellent ! do_shortcode is the one which executes the shortcode. Glad that you figured out on what to execute as per your theme.

    Thanks,
    Aakash

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.

Subscribe for updates

Get updates on the WordPress plugins, tips and tricks to enhance your WordPress experience. No spam. View newsletter