• Resolved mhicksimagine

    (@mhicksimagine)


    I want to display the excerpt of my popular posts using shortcodes. I am using the following sample as my base:

    [wpp range=weekly stats_views=1 order_by=views excerpt_length=55]

    I inserted the “excerpt_length” parameter and value, but only the name of the post, stats, and view count show up. Note that I get the same results even when I only write [wpp].

    Yes, I have searched the documentation, FAQ, and forums, but I have not found a solution that works for me. Please help!

    https://wordpress.org/plugins/wordpress-popular-posts/

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author Hector Cabrera

    (@hcabrera)

    Hi there!

    The default HTML output for the [wpp] shortcode doesn’t include the excerpt (see the post_html parameter info in Settings > WordPress Popular Posts > Parameters for more details). That’s why it isn’t showing up πŸ˜›

    Try this:

    [wpp range=weekly stats_views=1 order_by=views excerpt_length=55 post_html="<li>{title} {excerpt} {stats}</li>"]

    Thread Starter mhicksimagine

    (@mhicksimagine)

    Thank you for the quick response. I plugged in the code that you provided, but all I got were a pair a group of qoutes: “”””
    Not even the title showed up this time.

    There is actual content in the blog posts. They each have a paragraph of lorem ipsum currently. If you think of anything else, please let me know, I will continue fiddling around with the code.

    Plugin Author Hector Cabrera

    (@hcabrera)

    I’m away from the PC right now (it’s exactly 10:00 pm here) so can’t check it at the moment. I’ll take another look after a much needed good night’s sleep.

    Thread Starter mhicksimagine

    (@mhicksimagine)

    Much appreciated. I know you’re busy; people asking you to save them 24/7. Thank you Superman.

    Plugin Author Hector Cabrera

    (@hcabrera)

    Just tested the shortcode from above on both a custom theme and on the Twenty Fifteen theme and it works for me.

    Are you using the shortcode inside a post / page, inside another widget, etc?

    Thread Starter mhicksimagine

    (@mhicksimagine)

    I’m using it on a page, but I also tried it on a post just because. I switched to the Twenty-Thirteen theme and had the same problem; it only shows “”””””
    Maybe there’s something wrong with the whole site I’m working on; I am going behind someone else’s work and trying to fix it. It’s okay.

    Plugin Author Hector Cabrera

    (@hcabrera)

    Is this site online now? If so, I may be able to give you a hand once I get some spare time (probably during this weekend). That’s if you are OK with it, of course.

    Thread Starter mhicksimagine

    (@mhicksimagine)

    That sounds great. I will speak with the owner about it and let you know. If she decides to forget it I’ll also inform you. I appreciate your support either way.

    Thread Starter mhicksimagine

    (@mhicksimagine)

    Hey man, I got it! I don’t completely understand how, but it’s working. I have a local version of the site that I’ve been using the plugin on as well as the live version – obviously I work on the local version and then update the live one through FTP as its safer and best practice.

    In any case, whether its because of the URLs, the database, or my local setup here’s the issue:

    Local: The plugin works fine in the sidebar of the site, but not in the page area.
    Live: The plugin works fine on both occasions.

    There’s probably something wonky on my local setup that I’ll figure out down the road. As for now, this issue is resolved. Thank you so much for your patience and prompt support.

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Shortcode: Excpert not showing up’ is closed to new replies.