Ready to get started?Download WordPress


WP Customer Reviews
Include link to post in sidebar widget short code (7 posts)

  1. denisehummel
    Posted 2 years ago #

    to my sidebar widget to show recent reviews, and it works fine, but I would like the reader to be able to click on a link within the widget to go to the original post for which the review was made.

    Does anyone know how I might add that to the widget script?



  2. gowebsol
    Plugin Author

    Posted 2 years ago #

    We are working on that functionality for a future update, however it may be for a paid version of the plugin. The idea would be a sidebar widget that shows average rating, the latest review, and a link to the reviews page. How does that sound for what you need?

  3. corporatemagician
    Posted 2 years ago #

    Love the plugin! Great for my testimonials page but I would also like to display recent reviews in my sidebar...

    I've tried adding the following shortcode to a text widget in my sidebar and it just shows the shortcode instead of displaying the review as it does on my home page with the same shortcode: [WPCR_SHOW POSTID="ALL" NUM="1" SNIPPET="" MORE="view more" HIDECUSTOM="1" HIDERESPONSE="1"]

    For now I've removed the widget, as it doesn't look too great for my visitors.
    Any ideas on how I can get it working as Denise above has?

    Kind regards,

  4. denisehummel
    Posted 2 years ago #

    Gowebsol -- not sure if you received my responding email, but yes, yes, yes, that is what I want. A paid version of the plug-in does not scare me! Thanks for your quick response.

  5. denisehummel
    Posted 2 years ago #

    Corporatemagician -- that seems like so many custom Codex scripts ago. If I remember right I had to add this to the bottom of the WP Customer Review plugin editor. The short code in the text widget worked after that.

    if (!defined('IN_WPCR')) {
        global $WPCustomerReviews;
        $WPCustomerReviews = new WPCustomerReviews();
        register_activation_hook(__FILE__, array(&$WPCustomerReviews, 'activate'));
        register_deactivation_hook(__FILE__, array(&$WPCustomerReviews, 'deactivate'));

    Let me know if I'm wrong, and I'll keep looking.

  6. corporatemagician
    Posted 2 years ago #

    Hi Denise,

    Thanks for your reply!

    I already have that exact section of code at the bottom of the wp-customer-reviews.php so it must have been something else you changed to get it to work...

    If you remember what it is, please reply to let me know :)

  7. denisehummel
    Posted 2 years ago #

    Sorry about that corporatemagician...I did finally find it however.

    You need to add this to your function.php (mine is a theme so added to custom_function.php)

    add_filter('widget_text', 'do_shortcode');

    I added mine right before the existing script:


    The short code in the text widget worked for me with that added. Hope it works for you!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic