VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: 2dmaster on June 17, 2020, 13:59:15 PM

Title: how to load different product templates in sublayouts
Post by: 2dmaster on June 17, 2020, 13:59:15 PM
Hi,
in /mytpl/com_virtuemart/sublayouts/products.php

i try load products_ones.php  here and products_twos.php

<?php echo $this->loadTemplate('ones'); ?>
<?php echo $this->loadTemplate('twos'); ?>

<?php echo $this->loadTemplate('product_ones'); ?>
<?php echo $this->loadTemplate('product_twos'); ?>

<?php echo $product->loadTemplate('ones'); ?>
<?php echo $product->loadTemplate('twos'); ?>

<?php echo $product->loadTemplate('product_ones'); ?>
<?php echo $product->loadTemplate('product_twos'); ?>

not work i thinks, try with error (((

how to load different templates ? 3/1 4/2 style each second product is have some different tpl because.... pls help now!!!



Title: Re: how to load different product templates in sublayouts
Post by: pinochico on June 17, 2020, 18:19:00 PM
I don't understand what do you want
Title: Re: how to load different product templates in sublayouts
Post by: PRO on June 17, 2020, 18:25:51 PM
FROM WHERE, are you trying to load the template?


   echo shopFunctionsF::renderVmSubLayout($this->productsLayout,array('products'=>$this->products,'currency'=>$this->currency,'products_per_row'=>$this->perRow,'showRating'=>$this->showRating));


What styling are you trying to do? sounds like you need to do it with css.  You mean style every 2nd product etc?