Author Topic: customize virtuemart sub-category  (Read 19635 times)

nadrm

  • Beginner
  • *
  • Posts: 2
Re: customize virtuemart sub-category
« Reply #15 on: October 27, 2009, 22:34:36 pm »
could be useful to separate "template" of subcategories in Home Page from "template" of other pages of site.
With this in mind:
1. For set 3 numbers of categories on first (main) page need add code
/administrator/components/com_virtuemart/html/shop.index.php
Code:
$tpl->set( 'categories_per_row', 3 );
$categories = $tpl->fetch( 'common/categoryChildlist.tpl.php');


2. For set 1 number of categories on on other page need change
/components/com_virtuemart/themes/default/templates/common/categoryChildlist.tpl.php
Code:

$categories_per_row = 1


Simply create a new file called like: categoryChildlist.Home.tpl.php, personalize and use it only for Home Page, and left categoryChildlist.tpl.php for all remaining pages.
Hope may be useful to everybody!

bunak

  • Beginner
  • *
  • Posts: 37
Re: customize virtuemart sub-category
« Reply #16 on: May 08, 2010, 18:15:43 pm »
Simply create a new file called like: categoryChildlist.Home.tpl.php, personalize and use it only for Home Page, and left categoryChildlist.tpl.php for all remaining pages.
Hope may be useful to everybody!

Yes, it is a good idea. But how create and integrate the new "Home Page" template to the VM without do global change in scripts?