php - "Undefined" is display with discount price in magento -


i using magento 1.8.1 , trying display discount percent sell price on frontend.

with of site discount

i putting these code:

     <?php // discount percents output start ?>    <?php if($_finalprice < $_price): ?>      <?php $_savepercent = 100 - round(($_finalprice / $_price)*100); ?>          <p class="special-price yousave">       <span class="label"><?php echo $this->__('you save:') ?></span>     <span class="price">         <?php echo $_savepercent; ?>%     </span>     </p>  <?php endif; ?> 

in page: app/design/frontend/yourpackage/yourtheme/template/catalog/product/price.phtml

but after result showing this:enter image description here

now not able find why "undefined" showing here , how remove this.

please tell me how remove this.

i seen in question image need effect on product detail page have edit media.phtml

app\design\frontend\your_package\your_theme\default\template\catalog\product\view\media.phtml 

and in have same coding value. can make wrapper class override product image dynamic text on product image want.

you can use css in this page

i think work...try in way


Comments

Popular posts from this blog

c++ - Delete matches in OpenCV (Keypoints and descriptors) -

java - Could not locate OpenAL library -

sorting - opencl Bitonic sort with 64 bits keys -