on the index page, the code to display the fetured product is:
<?php if ($totalRows_FeaturedRS > 0) { // Show if recordset not empty ?>
<?php echo(' <div class="productWrapper">
<div class="image"><a href="Products_Detail.php?ProductID='. $row_FeaturedRS['ProductID'].'"><img src="imagesupload/'. $row_FeaturedRS['ProductThumb'] .'" alt="" width="120" /></a></div>
<div class="price">
<a href="Products_Detail.php?ProductID='. $row_FeaturedRS['ProductID'] .'"><h3>'. $row_FeaturedRS['ProductName'] .'</h3></a>
<h4>$'. (number_format($row_FeaturedRS['ProductPrice'],2)) .'</h4>
<p><a href="Products_Detail.php?ProductID='. $row_FeaturedRS['ProductID'] .'"><img src="Images/btn_learnmore.png" width="111" height="22" alt="Learn More" /></a></p>
</div>
</div>');
?>
<?php } // Show if recordset not empty ?>
<?php if ($totalRows_FeaturedRS == 0) { // Show if recordset empty ?>
<div class="productWrapper">
<div class="image"><img src="Images/pod1_img.png" width="131" /></div>
<div class="price">
<h3>Sample Product</h3>
<h4>$24.99</h4>
<p>Set the featured product from the Admin product details..</p>
<p><a href="#"><img src="Images/btn_learnmore.png" width="111" height="22" alt="Learn More" /></a></p>
</div>
</div>
<?php } // Show if recordset empty ?>
look for the 2 <h4> tags:
<h4>$'. (number_format($row_FeaturedRS['ProductPrice'],2)) .'</h4>
and:
<h4>$24.99</h4>
to change the currency symbol.
the code for showing the most popular product is:
<?php if ($totalRows_MostPopularRS > 0) { // Show if recordset not empty ?>
<?php
echo(' <div class="productWrapper">
<div class="image" style="width: 148px;"><a href="Products_Detail.php?ProductID='. $row_MostPopularRS['ProductID'] .'"><img src="imagesupload/'. $row_MostPopularRS['ProductThumb'] .'" alt="" width="120" /></a></div>
<div class="price">
<a href="Products_Detail.php?ProductID='. $row_MostPopularRS['ProductID'] .'"><h3>'. $row_MostPopularRS['ProductName'] .'</h3></a>
<h4>$'. number_format($row_MostPopularRS['ProductPrice'],2) .'</h4>
<p><a href="Products_Detail.php?ProductID='. $row_MostPopularRS['ProductID'] .'"><img src="Images/btn_learnmore.png" width="111" height="22" alt="Learn More" /></a></p>
</div>
</div>');
?>
<?php } // Show if recordset not empty ?>
<?php if ($totalRows_MostPopularRS == 0) { // Show if recordset empty ?>
<div class="productWrapper">
<div class="image" style="width: 148px;"><img src="Images/pod3_img.png" width="131" height="136" /></div>
<div class="price">
<h3>Sample Product</h3>
<h4>$249.99</h4>
<p>Displays your most popular product based on sales.</p>
<p><a href="#"><img src="Images/btn_learnmore.png" width="111" height="22" alt="Learn More" /></a></p>
</div>
</div>
<?php } // Show if recordset empty ?>
again, look for the two <h4> tags:
<h4>$'. number_format($row_MostPopularRS['ProductPrice'],2) .'</h4>
and
<h4>$249.99</h4>
to change the currency symbol.
on the admin\product_results.php page, the code for showing the price is:
<td><?php
if($row_MaxMinPrice["MinPrice"] > 0) {
echo "$".number_format($row_MaxMinPrice["MinPrice"],2);
} else {
echo "$".number_format($row_WADAProducts["ProductPrice"],2);
}
?>
<?php echo(($row_MaxMinPrice["MaxPrice"] != $row_MaxMinPrice["MinPrice"])?" - $" . number_format($row_MaxMinPrice["MaxPrice"],2):""); ?></td>
change that code to:
<td><?php
if($row_MaxMinPrice["MinPrice"] > 0) {
echo "£".number_format($row_MaxMinPrice["MinPrice"],2);
} else {
echo "£".number_format($row_WADAProducts["ProductPrice"],2);
}
?>
<?php echo(($row_MaxMinPrice["MaxPrice"] != $row_MaxMinPrice["MinPrice"])?" - £" . number_format($row_MaxMinPrice["MaxPrice"],2):""); ?></td>