Support » Plugin: WP Blog and Widget » Shortcode display issues with show content

  • Resolved mimicplay


    I’m using your plugin for the first time to work around a custom theme where the original developer is unavailable.

    I’m using your plugin’s shortcode to display a blog-roll type page since the original theme seems to have broken the “show recent blogs on a designated blog page” functionality. It seems your plugin is having trouble interpreting the “show_content=”true”” part of the shortcode (see screenshot image). I have the shortcode added to the text editor window of the regular content editor. The featured image and the post title show up alright, as does the Read More button, but the excerpt/preview text does not appear correctly.

    I can get around this by setting “show_content=”false”, but I would like to be able to enable that preview text if possible. This happens regardless of whether the shortcode is in the text editor window, or in a Simple Fields box, or in a Rich Text Excerpts box. I did add do_shortcode() to the single.php file for the Excerpt and Simple Fields boxes, but every text box on the post has the same issue showing the text preview.

    It seems to be wrapping that part of the shortcode in a <p> tag like so:
    <p class=”blog-short-content”>[blog limit=”4″ category=”9″ show_content=”false” show_author=”false” show_category_name=”false” show_date=”false” show_full_content=”false” content_words_limit=”15″]</p>

    But I can’t figure out how to prevent it from doing so. I tried installing a plugin called “Toggle wpautop” to try to get rid of that <p> tag, but no luck. Any ideas?

    Link to screenshot:

    Screenshot of issue

    • This topic was modified 4 years, 10 months ago by mimicplay.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Anoop Ranawat



    By looking at the screen-shot it looks like you inserted shortcode in the post editor. that is wrong.

    If you want to pass any parameter then you need to pass it to the shortcode itself.
    e,g. [blog content_words_limit=”15″]

    all the shortcode parameter pass here, not in the post’s editor.

    in post editor, you need to pass the content of that post not the short code.

    i think this might be the issue you facing.

    Thread Starter mimicplay


    Thank you for your help on this.

    If I understand you correctly, you are saying that I should not put the shortcode for your plugin the Post Editor window, even if I have it in the Text (not Visual) tab?

    I do currently have the shortcode in the text tab of the Post Editor, although if I’m not supposed to put it there, where else would it go? See screenshot for my current “blog roll page” shortcode:

    When you are talking about “passing any parameter, then you need to pass it to the shortcode itself,” are you talking about modifying either the single.php or page.php files of the theme to include some sort of “shortcode passing logic?” I am not a PHP developer at all, so please be gentle with me in your explanations if it is PHP-related 🙂

    Since I first posted my question, I notice another odd issue. When I copied+pasted your example shorcode (e,g. [blog content_words_limit=”15″]) into the post editor window, and then clicked Preview, it did something funny (screenshot):

    As you can see from that screenshot, now, even when I have show_content=true, it passes show_content=false when I preview post. And continues to do so with the new shortcode I pasted in. It actually seems to fill in all the shortcode parameters even though I have not.

    Does any of this help in troubleshooting the issue? Everything is fine as long as I set show_content=false, but I would ideally like to show that snippet and Read More button in the future.

    Plugin Author Anoop Ranawat



    you have passed the correct short-code in the page.

    for the second screen-shot where you are saying the result is not so good.

    please make sure you have enter the short-code parameter correctly. because when you copied it somewhere then it takes double quotes as a special character.
    (e,g. [blog content_words_limit=”15″])

    so, make sure you manually enter the parameter with double quotes.

    here I’m sending you the screen-shot of the post of our plugin.

    post url

    and here is the page short-code.

    Page URL

    we are happy to help you with your query.

    we have not receive this type of query before. can we have theme name you are using if it’s not an issue. so that we can check that theme with our plugin and provide you better support.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Shortcode display issues with show content’ is closed to new replies.