WordPress.org

Ready to get started?Download WordPress

Forums

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

  1. denisehummel
    Member
    Posted 2 years ago #

    I added [WPCR_SHOW POSTID="ALL" NUM="3" SNIPPET="" MORE="" HIDECUSTOM="0" HIDERESPONSE="0"]
    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?

    Thanks,
    Denise
    http://www.fotogfufu.com

    http://wordpress.org/extend/plugins/wp-customer-reviews/

  2. gowebsol
    Member
    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
    Member
    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,
    Oliver
    http://www.interactivemagician.co.uk

  4. denisehummel
    Member
    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
    Member
    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
    Member
    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
    Member
    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:

    add_filter('body_class','et_browser_body_class');

    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