woocommerce/templates/loop/rating.php

20 lines
437 B
PHP
Raw Normal View History

2013-01-12 10:53:24 +00:00
<?php
/**
* Loop Rating
*
* @author WooThemes
* @package WooCommerce/Templates
* @version 2.0.0
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
global $product;
2013-01-12 14:24:22 +00:00
if ( get_option( 'woocommerce_enable_review_rating' ) == 'no' || get_option( 'woocommerce_review_rating_loop' ) == 'no' )
2013-01-12 10:53:24 +00:00
return;
?>
<?php if ( $rating_html = $product->get_rating_html() ) : ?>
<?php echo $rating_html; ?>
<?php endif; ?>