• I wanted to add the reading time to all the posts in my blog archive. So I added the code

    <?php do_shortcode('[rt_reading_time]') ?>

    to my archive templates, but all I get is blank. No text whatsoever.

    This is the Ocean WP theme.

    Any idea why this doesn’t work, or can it work here at all?

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author Jason Yingling

    (@yingling017)

    the do_shortcode function doesn’t output unless it’s echod. Try using <?php echo do_shortcode('[rt_reading_time]'); ?>

    Just a note but that will only output the numerical reading time. If you want to add labels make sure to include those attributes with the shortcode.

Viewing 1 replies (of 1 total)
  • The topic ‘Add Reading Time to posts in Blog Archive’ is closed to new replies.