Welcome, Guest
Username: Password: Remember me
Use this Category for your support questions about Virtuemart Template - FashionMart (SKU# FLEX-00008)

TOPIC: Add SKU in product deatils, and category views?

Add SKU in product deatils, and category views? 5 years 11 months ago #10080

Hello

I try add Product SKU in product details pages, and category views?

any advice?

best regards
The administrator has disabled public write access.

Add SKU in product deatils, and category views? 5 years 11 months ago #10091

It is a very easy thing to do with all our other templates, because there is a plugin called "Flexible VM2 Template" to do this.

But with FashionMart, there is no plugin to control those small customization. you need a hard coding.

To add SKU, the PHP line to print the SKU number is this:

For Category browse page:
<div class="ProductKU"><?php echo JTEXT::_('COM_VIRTUEMART_CART_SKU');?>: <?php echo $product->product_sku ?></div>

For product details page:
<div class="ProductKU"><?php echo JTEXT::_('COM_VIRTUEMART_CART_SKU');?>: <?php echo $this->product->product_sku ?></div>

The product details and category browse page PHP files are located here:
Category browse page:
ROOT/templates/<yourjoomlatemplate>/html/com_virtuemart/category/default.php
(default.php, flexv2.php; what ever you are currently using, there are multiple category browse page layouts and you are using only one of them depends on what ever you chose from VM Configuration)

Product Details page:
ROOT/templates/<yourjoomlatemplate>/html/com_virtuemart/productdetails/default.php
(default.php or flexv2.php. There are 2 different product details page layouts and you are using only one of them depends on what ever you chose from VM Configuration)


Then you can stylize this SKU text with using the CSS and the .ProductKU class name. Something like;
.ProductKU {
text-size:10px;
}
The administrator has disabled public write access.
Time to create page: 0.119 seconds

MaterialMart

for Virtuemart 3

Google's Material Design has finally arrived to Virtuemart

Virtumart Template - MaterialMart Virtumart Template - CleanMart Virtumart Template - CleanMart Virtumart Template - CleanMart

Fully responsive!

Buy Now   |   Live Demo