VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: gofer123 on April 14, 2014, 01:54:47 AM

Title: Upgrading VM
Post by: gofer123 on April 14, 2014, 01:54:47 AM
Hi all,
If I have a site in VM v2.0 and want to upgrade to the latest version of VM will the css style changes I have made, will they be over ridden by the upgrade and style changed back to the default VM styling?
Thanks in advance.
Title: Re: Upgrading VM
Post by: JoomTut on April 14, 2014, 04:39:57 AM
- Yes. If the file has been modified directly.
- No. If the file has been modified by creating template override.
More information about Joomla! template override: http://docs.joomla.org/How_to_override_the_output_from_the_Joomla!_core
Title: Re: Upgrading VM
Post by: gofer123 on April 14, 2014, 05:14:08 AM
Thanks for that
cheers
Title: Re: Upgrading VM
Post by: gofer123 on April 14, 2014, 05:25:19 AM
Just thinking about that, the css file is: vmsite-ltr.css which is quite separate from the Joomla template files. Do I still need an template override?
If I was to duplicate the Joomla template and name it something different wouldn't it then be safe from being overwritten?
cheers
Title: Re: Upgrading VM
Post by: jenkinhill on April 14, 2014, 10:41:44 AM
I see some confusion here. If you have only made edits to vmsite-ltr.css rather than make css overrides (different from template overrides) then the easiest way to keep those style changes is to  make a copy of your edited css file, rename it (I use custom.css) and edit the Joomla template index.php file to load that file as the last event in the head area. This will then override the new  vmsite-ltr.css that will be created in an upgrade, and any fine tuning can be made within the custom.css file.

I use a custom.css file in just about every Joomla site I build.
Title: Re: Upgrading VM
Post by: gofer123 on April 15, 2014, 00:00:38 AM
Many thanks, I understand what I've got to do now.
cheers