VirtueMart Forum

VirtueMart 1.1.x [ Old version - no longer supported ] => Themes & Layout Problems and Customization VM 1.1 => Topic started by: allamistakeo19 on May 22, 2015, 12:30:52 pm

Title: How can I override the shop front page?
Post by: allamistakeo19 on May 22, 2015, 12:30:52 pm
Hi,

Can someone please provide instructions on how to override the following file?
Code: [Select]
components/com_virtuemart/views/virtuemart/tmpl/default.php
I have saved a modified version at the following path, but it doesn't get picked up:
Code: [Select]
templates/my_template/html/com_virtuemart/views/virtuemart/tmpl/default.php
What I would like to achieve is to get the categories to be displayed above the store description instead of below. I got it to work by editing the original file, but it would be better if I could use an override instead.

Thanks in advance


Edit: this is about VirtueMart 3, not VirtueMart 1.1.x; I must have posted in the wrong discussion group
Title: Re: How can I override the shop front page?
Post by: allamistakeo19 on May 30, 2015, 08:18:04 am
Answering my own question...

I had to look deep into the code to investigate this, but I finally found how to properly override the shop front page layout.
Title: Re: How can I override the shop front page?
Post by: GJC Web Design on May 30, 2015, 09:17:25 am
Quote
1. The new version of default.php must be saved in the folder "templates/my_template/html/com_virtuemart/virtuemart/"
2. The new version of default.php must have a filename that is different from "default.php" and is not allowed to contain underscores
3. The new layout must be selected in the VirtueMart CONFIGURATION > Configuration > Templates > VirtueMart Home Page Settings > Layout for your home page

1 is correct
2. is only partly correct - you can use the name default.php and then 3 isn't necessary
Yes - no underscores!