Exemplo n.º 1
0
</div>

<?php 
}
if ($osC_Product->getData('reviews_average_rating') > 0) {
    ?>

<p><?php 
    echo $osC_Language->get('average_rating') . ' ' . osc_image(DIR_WS_IMAGES . 'stars_' . $osC_Product->getData('reviews_average_rating') . '.png', sprintf($osC_Language->get('rating_of_5_stars'), $osC_Product->getData('reviews_average_rating')));
    ?>
</p>

<?php 
}
$counter = 0;
$Qreviews = osC_Reviews::getListing($osC_Product->getID());
while ($Qreviews->next()) {
    $counter++;
    if ($counter > 1) {
        ?>

<hr style="height: 1px; width: 150px; text-align: left; margin-left: 0px" />

<?php 
    }
    ?>

<p><?php 
    echo osc_image(DIR_WS_IMAGES . 'stars_' . $Qreviews->valueInt('reviews_rating') . '.png', sprintf($osC_Language->get('rating_of_5_stars'), $Qreviews->valueInt('reviews_rating'))) . '&nbsp;' . sprintf($osC_Language->get('reviewed_by'), $Qreviews->valueProtected('customers_name')) . '; ' . osC_DateTime::getLong($Qreviews->value('date_added'));
    ?>
</p>
<?php

/*
  $Id: reviews.php $
  TomatoCart Open Source Shopping Cart Solutions
  http://www.tomatocart.com

  Copyright (c) 2009 Wuxi Elootec Technology Co., Ltd;  Copyright (c) 2007 osCommerce

  This program is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License v2 (1991)
  as published by the Free Software Foundation.
*/
$Qreviews = osC_Reviews::getListing();
?>

<h1><?php 
echo $osC_Template->getPageTitle();
?>
</h1>

<?php 
while ($Qreviews->next()) {
    ?>

<div class="moduleBox">
  <h6>
    <span style="float: right; margin-right: 5px"><?php 
    echo osC_DateTime::getShort($Qreviews->value('date_added'));
    ?>
</span>