![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/old/vendor/magento/module-review/view/frontend/templates/helper/ |
<?php /** * Copyright © Magento, Inc. All rights reserved. * See COPYING.txt for license details. */ /** * @var \Magento\Review\Block\Product\ReviewRenderer $block * @var \Magento\Framework\View\Helper\SecureHtmlRenderer $secureRenderer */ $url = $block->getReviewsUrl() . '#reviews'; $urlForm = $block->getReviewsUrl() . '#review-form'; ?> <?php if ($block->isReviewEnabled() && $block->getReviewsCount()): ?> <?php $rating = $block->getRatingSummary(); ?> <div class="product-reviews-summary<?= !$rating ? ' no-rating' : '' ?>" itemprop="aggregateRating" itemscope itemtype="http://schema.org/AggregateRating"> <?php if ($rating):?> <div class="rating-summary"> <span class="label"><span><?= $block->escapeHtml(__('Rating')) ?>:</span></span> <div class="rating-result" id="rating-result_<?= $block->escapeHtmlAttr($block->getProduct()->getId()) ?>" title="<?= $block->escapeHtmlAttr($rating) ?>%" > <span> <span> <span itemprop="ratingValue"><?= $block->escapeHtml($rating); ?> </span>% of <span itemprop="bestRating">100</span> </span> </span> </div> </div> <?= /* @noEscape */ $secureRenderer->renderStyleAsTag( 'width:' . $block->escapeHtmlAttr($rating) . '%', '#rating-result_' . $block->getProduct()->getId() . ' span' ) ?> <?php endif;?> <div class="reviews-actions"> <a class="action view" href="<?= $block->escapeUrl($url) ?>"> <span itemprop="reviewCount"><?= $block->escapeHtml($block->getReviewsCount()) ?></span> <span><?= ($block->getReviewsCount() == 1) ? $block->escapeHtml(__('Review')) : $block->escapeHtml(__('Reviews')) ?> </span> </a> <a class="action add" href="<?= $block->escapeUrl($urlForm) ?>"> <?= $block->escapeHtml(__('Add Your Review')) ?> </a> </div> </div> <?php elseif ($block->isReviewEnabled() && $block->getDisplayIfEmpty()): ?> <div class="product-reviews-summary empty"> <div class="reviews-actions"> <a class="action add" href="<?= $block->escapeUrl($urlForm) ?>"> <?= $block->escapeHtml(__('Be the first to review this product')) ?> </a> </div> </div> <?php endif; ?>