WordPress.org

Ready to get started?Download WordPress

Forums

WP Customer Reviews
Sidebar Working but the Form Now Shows on Every Post (6 posts)

  1. frankjackson
    Member
    Posted 2 years ago #

    I'm using v2.4.2
    This is the shortcode being used in the sidebar "text" widget:

    [WPCR_SHOW POSTID="ALL" NUM="100" SNIPPET="100" MORE="read more" HIDECUSTOM="0" HIDERESPONSE="0"]

    Reviews are showing perfectly in the sidebar but since doing it, the reviews form now shows up in the content area of every POST on my site.

    I checked each POST and the checkbox is NOT checked on any of the posts.
    The only place I want the reviews form to show up is on my testimonials PAGE (and it does just fine).

    I already tried the "disable plugin for all existing posts" button in admin and that did not do anything.

    Also note:
    Google rich snippits only shows the last review submitted (ie, no aggregate):

    hproduct
    identifier
    type = SKU
    Warning: Missing required field "fn".
    review hreview
    version = 0.3
    summary = I completely agree with what everyone else has already said. These are some glowing reviews and for ...
    type = product
    reviewer hcard
    fn = Mike DiAmbrosia
    n
    family-name = DiAmbrosia
    given-name = Mike
    dtreviewed = 2011-09-03T03:07:47+00:00
    rating
    value (normalized to 5.0 scale) = 5.0
    value = 5
    review hreview-aggregate
    summary = Reviews for my site
    rating
    best = 0.0
    average (normalized to 5.0 scale) = 5.0
    average = 0.0
    count = 0
    Warning: count field is 0.
    Warning: votes field is 0.

    PS. For anyone having trouble getting the shortcodes to work in the sidebar I had to download a plugin called Shortcodes in Sidebar Widgets

    Thanks in advance for help w/ this bompus (or anyone else)

    fj

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

  2. frankjackson
    Member
    Posted 2 years ago #

    EDIT:

    I just realized that the form is also showing up on all PAGES too (earlier I thought it was just all POSTS).

  3. bompus
    Member
    Plugin Author

    Posted 2 years ago #

    I am looking into this issue and will try to have it resolved soon. Thanks!

  4. frankjackson
    Member
    Posted 2 years ago #

    @bompus

    I switched the theme and everything works as it should so it may be a very isolated thing (ie, not your problem) thanks though.

  5. nielsenrc
    Member
    Posted 2 years ago #

    @bompus was this ever resolved? The review form shows up in the content area on every page when we try to include the
    <?php echo do_shortcode('[WPCR_SHOW POSTID="ALL" NUM="1" SNIPPET="" MORE="" HIDECUSTOM="0" HIDERESPONSE="0"]'); ?> in our sidebar. Any ideas?

  6. nielsenrc
    Member
    Posted 2 years ago #

    OK - well based on my (very quick) reading of the source code:

    Putting the testimonial on a global element like the sidebar will produce the form on all pages because the only conditions that are checked are whether or not the form should be above or below the testimonial.

    Because I don't have a lot of time (and I need to use this plugin) - I hardcoded a conditional statement in the do_the_content() function that checks for what page it's on. Find these two conditionals in wp-customer-reviews.php:

    if ($this->options['form_location'] == 1) {...}
    if ($this->options['form_location'] == 0) {...}

    and wrap the call to $this->show_reviews_form() call in another conditional like this:

    if($_SERVER['REQUEST_URI'] == '/only-page-form-should-be-on') {
    $the_content .= $this->show_reviews_form();
    }

    Ghetto fix but it worked for me. We were able to tentatively confirm that the problem seemed to be theme dependent - but what it is about a particular theme that makes it work or not work is beyond me.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic