Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Popup Review Product Form
 
carsal
Member
 
Total Posts:  52
Joined:  2008-03-31
Medellin, Colombia
 

I am trying to get a link in the product page to popup the review form, instead of going to the reviews list, which I particularly don’t like. I prefer everything to be in the same page and prevent the user from having to go back and forth.

I have created this link in the product view.phtml:

<a href="#" onclick="popWin('<?php echo $this->helper('catalog/product_review')->getReviewUrl() ?>','review','width=500,height=500,resizable=yes,scrollbars=yes')"><?php echo $this->__('Review Item'?></a>

In the catalog.xml I have included this section:

<!--
Product review form popup
-->

    <
catalog_product_review_index>
        <!-- 
Mage_Catalog -->
        <
reference name="root">
            <
action method="setTemplate"><template>page/one-column.phtml</template></action>
        </
reference>
        <
reference name="head">
            <
action method="addJs"><script>scriptaculous/scriptaculous.js</script></action>
            <
action method="addJs"><script>varien/product.js</script></action>
        </
reference>
        <
reference name="content">
            <
block type="review/form" name="product.info.review.form" as="review_link" template="review/form.phtml" />
        </
reference>
    </
catalog_product_review_index>

Although I don’t know if I should be doing it in the review.xml

I figure I have to create the class Catalog/Helper/Product/Review.php and Catalog/Block/Product/Review.php but that is as far as my PHP takes me.

Can anyone help with this code as I think it would be helpfull.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Dave_83
Jr. Member
 
Avatar
Total Posts:  26
Joined:  2009-06-25
 

Bump!

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top