News:

Support the VirtueMart project and become a member

Main Menu

Display SKU in Category Layout

Started by webzight, June 28, 2012, 19:57:59 PM

Previous topic - Next topic

webzight

I'm trying to get the SKU to display in the Category layout without having to manually put said SKU in the Short Description box 8)

I tried using the same code from the product details layout but it will not display the SKU, it will show the SKU title text, but not the SKU number :o

Here is the code I am attempting to use:
<?php //Product SKU
   if (!(($this->product->product_sku)==0)) { ?>
   
               <span class="product-fields-title" >
               <?php echo JText::_('COM_VIRTUEMART_PRODUCT_SKU') ?>
               </span>
               <?php echo $this->product->product_sku ?>
               </br>
            <?php } ?>

I can comment out the JTEXT code and it disappears, so I am led to believe the code is working partially :o

Addendum:  I am placing this code in the same loop in between the 'Short Description' and the 'Price' calls :o

What am I doing wrong ???
May the Cloud be with you :)

jenkinhill

Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

webzight

Thank You, Thank You, Mr Kelvyn :D
IT works 8)
May the Cloud be with you :)