Post by caspara » Mon Mar 22, 2010 11:30 am

What would be the easiest way to automatically approve (enable) all reviews without having to do so manually for each one in the Admin.

Thanks,
Chris
Last edited by caspara on Mon Mar 22, 2010 11:50 am, edited 1 time in total.

DownloadXS.com : Stock Photos & Vintage Illustrations, Fresh PLR Articles and more.
http://www.DownloadXS.com


Newbie

Posts

Joined
Fri Feb 19, 2010 2:16 am

Post by caspara » Mon Mar 22, 2010 11:46 am

Actually, I figured it out.

All you have to do is go into phpMyAdmin, click on the 'review' table in your database, then click on the Structure tab at the top within phpMyAdmin, editing the 'status' field, changing the default status from 0 (disabled) to 1 (enabled).

Now, each time someone leaves a review, it will be enabled (approved) automatically. I imagine you could easily change other things that require Administrative approval in this way.

TWO SMALL ISSUES WITH THE REVIEW/RATINGS SYSTEM:

1. The reviews/ratings function on OpenCart does not keep people from rating a particular product more than once. It would be nice if thee were some sort of cookie system that prevented this.

2. When sorting a list of products by Rating, OpenCart treats a product with one 5 star rating the same as a product with two 5 star ratings (the product with two 5 star ratings should be shown first). I'll have to investigate this further.

Good luck.

DownloadXS.com : Stock Photos & Vintage Illustrations, Fresh PLR Articles and more.
http://www.DownloadXS.com


Newbie

Posts

Joined
Fri Feb 19, 2010 2:16 am

Post by rph » Mon Mar 22, 2010 3:20 pm

caspara wrote:1. The reviews/ratings function on OpenCart does not keep people from rating a particular product more than once. It would be nice if thee were some sort of cookie system that prevented this.
There are pros and cons to changing ratings. The current system encourages more reviews by being easy access (this also makes it easy to game). People will sometimes also do follow-up reviews which may change their overall rating of the product so multiple reviews can be good too.

One easy thing that can be done to fix gaming is logging the IP of reviewers. That'll make any immediate (though not long-term) Tom Foolry apparent. The only way to really control it, though, would be ending anonymous reviews altogether and only allowing registered users to submit them.
2. When sorting a list of products by Rating, OpenCart treats a product with one 5 star rating the same as a product with two 5 star ratings (the product with two 5 star ratings should be shown first). I'll have to investigate this further.
This one affects a lot of e-commerce sites (even Amazon I believe). It does seem silly that one person rating a product 5 stars would beat out a product with 100 people rating it 4 stars. Maybe some options like "Lifetime Rating" could be implemented which weights the number of reviews along with rating.

-Ryan


rph
Expert Member

Posts

Joined
Fri Jan 08, 2010 5:05 am
Location - Lincoln, Nebraska

Post by caspara » Tue Mar 23, 2010 3:43 am

rph, you have made very good points that I did not consider. I have noticed that many top level e-commerce sites do seem to have the problem of ranking a product with, for example, one 5 star rating higher than a more established product with many 4 star ratings. Perhaps this is a means to keep the newer products on top to broaden their product line. Otherwise, it seems like there could be an algorithm in place to sort the products better.

As for the OpenCart ratings system allowing one person to rate a particular product multiple times, I might replace it with a digg-like thumbs up or down system like this:

http://codecanyon.net/item/thumbsup/50411

It seems to use cookies to at least discourage over-rating something.

Thanks for your great input.

DownloadXS.com : Stock Photos & Vintage Illustrations, Fresh PLR Articles and more.
http://www.DownloadXS.com


Newbie

Posts

Joined
Fri Feb 19, 2010 2:16 am

Post by rph » Tue Mar 23, 2010 4:20 am

Problem is cookies only work for honest people. Anyone who wants to trash a competitor's product or pump up their own would just clear their cookies and go on their merry way.

-Ryan


rph
Expert Member

Posts

Joined
Fri Jan 08, 2010 5:05 am
Location - Lincoln, Nebraska

Post by jnoh » Sat Oct 16, 2010 3:04 am

All you have to do is go into phpMyAdmin, click on the 'review' table in your database, then click on the Structure tab at the top within phpMyAdmin, editing the 'status' field, changing the default status from 0 (disabled) to 1 (enabled).
You can also edit the model file (model/catalog/review.php)

Edit the following code:

Code: Select all

public function addReview($product_id, $data) {
        $this->db->query("INSERT INTO " . DB_PREFIX . "review SET author = '" . $this->db->escape($data['name']) . "', customer_id = '" . (int)$this->customer->getId() . "', product_id = '" . (int)$product_id . "', text = '" . $this->db->escape(strip_tags($data['text'])) . "', rating = '" . (int)$data['rating'] . "', date_added = NOW()'");
    }
to look like this:

Code: Select all

public function addReview($product_id, $data) {
        $this->db->query("INSERT INTO " . DB_PREFIX . "review SET author = '" . $this->db->escape($data['name']) . "', customer_id = '" . (int)$this->customer->getId() . "', product_id = '" . (int)$product_id . "', text = '" . $this->db->escape(strip_tags($data['text'])) . "', rating = '" . (int)$data['rating'] . "', date_added = NOW(), status = '1'");
    }
Diff:

Code: Select all

, status = '1'

Newbie

Posts

Joined
Sat Oct 16, 2010 3:00 am

Post by crqdesigns » Mon Mar 26, 2012 12:29 pm

how can it be refreshed automatically so they can see it straight away without refreshing the browser

Newbie

Posts

Joined
Fri Mar 16, 2012 9:22 am

User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am

Post by Qphoria » Wed Apr 16, 2014 3:39 am

Here's a vQmod to auto approve reviews
http://forum.opencart.com/viewtopic.php?f=131&t=52219

Image
Donate!|OpenCart Basics|GeoZones
Image


User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am
Who is online

Users browsing this forum: No registered users and 25 guests