Post by jessicadg » Fri Mar 16, 2012 9:02 am

HI,
I searched for such a topic but couldn't find anything so I decided to post it here and hopefully someone can help.
I am new to OpenCart...decided to give it a go after few Magento instals/uninstalls (was too.... complicated) :)
So far everything goes fine and I am happy I picked OC for my shop.
I spent few hours trying to disable (remove) rating (stars) from Reviews. No matter what icon will go there - I just don't want to see the stars! (I cant stand them)
I tried with product.tpl but when I remove the rating it's still ask me to rate. I guess it is the JS somewhere in the template but couldn't find it.

I want to keep the Reviews in the format they are, just want to disable the star rating.
Any help is welcome

Thanks


Posts

Joined
Fri Mar 16, 2012 8:17 am

Post by MarketInSG » Fri Mar 16, 2012 10:49 am

Easy. Just edit the following files:

In catalog/view/theme/default/template/product/product.tpl

Find & remove

Code: Select all

<img src="catalog/view/theme/default/image/stars-<?php echo $rating; ?>.png" alt="<?php echo $reviews; ?>" />
Find

Code: Select all

<b><?php echo $entry_rating; ?></b> <span><?php echo $entry_bad; ?></span>&nbsp;
    <input type="radio" name="rating" value="1" />
    &nbsp;
    <input type="radio" name="rating" value="2" />
    &nbsp;
    <input type="radio" name="rating" value="3" />
    &nbsp;
    <input type="radio" name="rating" value="4" />
    &nbsp;
    <input type="radio" name="rating" value="5" />
    &nbsp; <span><?php echo $entry_good; ?></span><br />
    <br />
Edit to

Code: Select all

<input type="hidden" name="rating" value="5" />
And in catalog/view/theme/default/template/module/ (featured.tpl, latest.tpl, specials.tpl, bestseller.tpl)
Find and remove

Code: Select all

        <?php if ($product['rating']) { ?>
        <div class="rating"><img src="catalog/view/theme/default/image/stars-<?php echo $product['rating']; ?>.png" alt="<?php echo $product['reviews']; ?>" /></div>
        <?php } ?>
That's all the place if I didn't remember wrongly. :D


User avatar

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

Post by jessicadg » Fri Mar 16, 2012 8:12 pm

Hi MarketInSG,
thanks for your effort but unfortunately it didn't work. I follow all the steps from your post but No!
It still ask me to select review rating...
The Stars dont appear but I cant submit the review as the system asks me to rate....
I think it is something to do with Ajax down at the bottom of the product.tpl but cant find it...
It drives me mad...thought its something easy and quick to do :(
By the way I am using the latest version of OpenCart - 1.5.2.1

Please Help!

If I cant remove the ratings(starts) I have to totally remove Reviews and find some module or extension to replace the default OC Review system ( just because of few stars!!! ) :( :(


Posts

Joined
Fri Mar 16, 2012 8:17 am

Post by MarketInSG » Fri Mar 16, 2012 8:30 pm

Remove review system, use our Facebook mod: http://www.opencart.com/index.php?route ... order=DESC

You have to remove accordingly. If you are not using default theme, then remove from your respective theme.


User avatar

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

Post by MarketInSG » Fri Mar 16, 2012 8:45 pm

Find

Code: Select all

<b><?php echo $entry_rating; ?></b> <span><?php echo $entry_bad; ?></span>&nbsp;
    <input type="radio" name="rating" value="1" />
    &nbsp;
    <input type="radio" name="rating" value="2" />
    &nbsp;
    <input type="radio" name="rating" value="3" />
    &nbsp;
    <input type="radio" name="rating" value="4" />
    &nbsp;
    <input type="radio" name="rating" value="5" />
    &nbsp; <span><?php echo $entry_good; ?></span><br />
    <br />
edit to

Code: Select all

<input type="radio" name="rating" value="1" style="display:none"/>
    &nbsp;
    <input type="radio" name="rating" value="2" style="display:none"/>
    &nbsp;
    <input type="radio" name="rating" value="3" style="display:none"/>
    &nbsp;
    <input type="radio" name="rating" value="4" style="display:none"/>
    &nbsp;
    <input type="radio" name="rating" value="5" style="display:none" checked/><br>


User avatar

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

User avatar

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

Post by jessicadg » Fri Mar 16, 2012 9:04 pm

Ah MarketInSG,
I am in love :) :) :)

Worked like charm!

Thank You


Posts

Joined
Fri Mar 16, 2012 8:17 am

Post by matt71 » Sat Mar 16, 2013 1:29 am

Or...

You can do what I just did to hide the stars.

Find the "star" image files in your templates image folder and simply replace their content with a placeholder. In this case, I just downloaded the files, opened them in Photoshop, used the erase tool to erase the stars, saved them as the same file names and then reuploaded them.

Worked like a charm. Just save the original files in case you decide to reactive them again.

Matt


Posts

Joined
Sat Jan 19, 2013 4:13 am

Post by classic_rock » Wed Aug 27, 2014 2:43 am

Hello,
after I edited files that you mentioned above, it works and rating was removed from reviews, but I have this error :
Notice: Undefined index: name in /home/musicfor/public_html/shop/vqmod/vqcache/vq2-catalog_controller_product_product.php on line 174

How can I fix this error?


Posts

Joined
Wed Aug 27, 2014 2:32 am

User avatar

Posts

Joined
Wed Nov 16, 2011 11:53 am
Location - Singapore

Post by bavl » Wed Dec 28, 2016 5:22 pm

MarketInSG wrote:Find

Code: Select all

<b><?php echo $entry_rating; ?></b> <span><?php echo $entry_bad; ?></span>&nbsp;
    <input type="radio" name="rating" value="1" />
    &nbsp;
    <input type="radio" name="rating" value="2" />
    &nbsp;
    <input type="radio" name="rating" value="3" />
    &nbsp;
    <input type="radio" name="rating" value="4" />
    &nbsp;
    <input type="radio" name="rating" value="5" />
    &nbsp; <span><?php echo $entry_good; ?></span><br />
    <br />
edit to

Code: Select all

<input type="radio" name="rating" value="1" style="display:none"/>
    &nbsp;
    <input type="radio" name="rating" value="2" style="display:none"/>
    &nbsp;
    <input type="radio" name="rating" value="3" style="display:none"/>
    &nbsp;
    <input type="radio" name="rating" value="4" style="display:none"/>
    &nbsp;
    <input type="radio" name="rating" value="5" style="display:none" checked/><br>
I've tried this a few times, and every time it messed up the order of the tabs of my product page. Didn't get read of the stars though


Posts

Joined
Mon Dec 19, 2016 9:31 pm
Who is online

Users browsing this forum: No registered users and 12 guests