By the default, the "x Review(s)" link, links to the review page. How do we make it link to the "Review" tab instead, using the default RWD template?


When you click the "x Review(s)" link, the "Reviews" tab is activated, and page scrolls down to it...

Other stuff:

app.js controls this via:

//Toggle on tab (li) click.
    if (hasTabs) {
        lis.on('click', function (e) {
            toggleClasses(jQuery(this), lis);
        //Open the first tab.

1 Answer 1


I've had the same issue and here's a solution.

Please note there will probably be a better way of doing this but I haven't had time to look into this much.

So, I believe your issue is that the "10 Reviews" link jumps down to the reviews tab, but the "Add you review" link doesn't. If you look in the summary/summary_short.phtml files, the links are exactly the same...

<a href="<?php echo $this->getReviewsUrl() ?>">

If you look into the method itself, you can see that it's just redirecting to the reviews page...

public function getReviewsUrl()
        return Mage::getUrl('review/product/list', array(
           'id'        => $this->getProduct()->getId(),
           'category'  => $this->getProduct()->getCategoryId()

I've had a quick look for some script that forces the "10 Reviews" link to jump down the page but can't find anything. Here's a work around...

First off, you'll need to add the review form into the reviews tab... (local.xml)

  <reference name="product.info">
    <block type="review/product_view_list" name="product.reviews.tab" as="reviews" template="review/product/view/list.phtml" after="product.spec">
      <action method="addToParentGroup"><group>detailed_info</group></action>
      <action method="setTitle" translate="value"><value>Reviews</value></action>
      <block type="review/form" name="product.review.form" as="review_form">
        <block type="page/html_wrapper" name="product.review.form.fields.before" as="form_fields_before" translate="label">
          <label>Review Form Fields Before</label>
          <action method="setMayBeInvisible"><value>1</value></action>

Next off, remove the href from the links and add a class which we'll pick up with script. Do this in the summary_short/summary.phtml files...


<a href="<?php echo $this->getReviewsUrl() ?>#review-form"><?php echo $this->__('Add Your Review') ?></a>


<a class="no-rating-link"><?php echo $this->__('Add Your Review') ?></a>

Then if you look in app.js, you'll see..

//Open the first accordion if desired.
        if (startOpen) {

Underneath that, add the following script which will open the reviews tab and also make the page jump down to the reviews form...

// Added to force review links to jump down to review tab
            window.location.href = '#review-form';

The reason i said this could be done better is because obviously, if you change the position of the reviews tab within the tabs, this will then open the wrong tab because the dts.eq(2) will always open the 3rd tab. Nevertheless, it's a workaround for you. Hope this helps!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.