Hi,
How can I add an extra category view to use for some categories. (used to display just sale price. Not normal and saleprice.)
I'm using a template but got confused about what file should be modified and where this should be placed.
Can't find info for latest version VirtueMart 3.4.2.
Thanks in advance,
Pas
templates/yourtemplate/html/com_virtuemart/category/myown.php
myown is a copy of default.php view your changes, but price use sublayout so you need to modify productsLayout too and price layout
Thank you,
But where should I change the price and productslayout...is this in sublayouts?
Should these be renamed to prices_myown.php and products_myown.php?
and how can I make sure these are used in my custom category layout myown.php?
Thanks and regards,
Pas
when you create a new layout, you see it backend on edit a category
in the list Category Layout :
default
myown
So you can switch to this layout
Else you can change directly Sublayouts for products in category
Any products Sublayouts are in sublayouts and begin with products_XXX.php
The prices are displayed using
echo shopFunctionsF::renderVmSubLayout('prices',array('product'=>$product,'currency'=>$currency));
and you can change for eg too
echo shopFunctionsF::renderVmSubLayout('myprices',array('product'=>$product,'currency'=>$currency));
to use file .../sublayouts/myprices.php to render the prices list.
So it depend your needs
Thanks for the explanation.
I created the new files(duplicate and rename) and I can choose these in category config.
But I don't see any products in the category on front end.
What could be wrong?
Thanks,
Pas
You have to verify using php vardump or vmdebug if the right files are loaded.