0

How to perform rating in any custom product listing page so that user do not have to go to product detail page to rate it? I got suggestions to look at Magento 2 : Show product ratings for each star, average ratings and % of 5 star ratings on product page . This code works to get review. But I need a way so that I can post review and get it recorded in database.

1
  • it's not duplicate, that solutioin is about reading data, I am talking about writing reviews to database from almost anywhere where products are listed.
    – P S
    May 18, 2017 at 5:34

1 Answer 1

0

Call this line in your file where you want to add the reviews html:

echo $this->_reviewsHelperBlock->getSummaryHtml($_product, false, false);
2

Your Answer

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

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