VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: katagram on February 08, 2012, 08:50:31 AM

Title: change add to cart button virtuemart 2.0
Post by: katagram on February 08, 2012, 08:50:31 AM
I've been trawling the forum for hours and cant find an answer for what should be a very straight forward task.

How do I change the hideous green add to cart button??

I am running J 1.5 and VM 2.0 I have an artisteer template for Joomla, and would love to use the buttons from joomla theme for virtuemart too, but just beaing able to change to colour to suit the rest of my website would be sufficient.

Can anyone point me in the right direction? thankyou!!  :)
Title: Re: change add to cart button virtuemart 2.0
Post by: jenkinhill on February 08, 2012, 10:40:37 AM
Forum search:  http://forum.virtuemart.net/index.php?topic=91947
Title: Re: change add to cart button virtuemart 2.0
Post by: terryarthur on March 01, 2012, 23:07:18 PM

You just use the new template overrides by adding a folder to your template called html with a folder in it called com_virtuemart and inside that put a folder called assets and inside that add a copy the file vmsite-ltr.css from /components/com_virtuemart/assets/css

and then at around line 50 or so edit span.addtocart-button to use whatever you like for a button like so

span.addtocart-button {color:fff;width:141px;background: url(../images/vmgeneral/add-to-cart_h&h.gif) no-repeat;font-size:14px;cursor:pointer;height:29px;text-align:center;letter-spacing:1px;padding:4px 5px;}

Hope that helps,

Terry Arthur
Title: Re: change add to cart button virtuemart 2.0
Post by: jakobe on March 31, 2012, 00:26:11 AM
this has to be the most confusing version of Virtuemart yet!

in order to change anything you have to write custom code and upload custom css and files.

there is no simple "select a template and layout" anymore...this defeats the whole purpose of joomla....and is against why we use the Joomla platform, its supposed to be relatively simple.

Even the template designers have backed off of making Templates for Virtuemart 2.0


this is not simple, this is a nightmare.

I am beginning to hate Virtuemart now...sure its powerful, but it looks like its from 1998, and the looks of it keep getting worse and worse.

Why cant the developer just for once...just maybe take 30 minutes and put decent sized and resolution images in the sample data?
These images and sizes have been used for at least 5 years!

its the little things like these that make folks look at Virtuemart with frustration and they wont donate until it looks solid and pretty.

Title: Re: change add to cart button virtuemart 2.0
Post by: speedpacer on June 27, 2012, 21:52:30 PM
If you're hungry and someone offers you a free ham sandwich, do you complain that it's not turkey?
Title: Re: change add to cart button virtuemart 2.0
Post by: beanman1 on January 31, 2013, 17:59:34 PM
Quote from: terryarthur on March 01, 2012, 23:07:18 PM

You just use the new template overrides by adding a folder to your template called html with a folder in it called com_virtuemart and inside that put a folder called assets and inside that add a copy the file vmsite-ltr.css from /components/com_virtuemart/assets/css

and then at around line 50 or so edit span.addtocart-button to use whatever you like for a button like so

span.addtocart-button {color:fff;width:141px;background: url(../images/vmgeneral/add-to-cart_h&h.gif) no-repeat;font-size:14px;cursor:pointer;height:29px;text-align:center;letter-spacing:1px;padding:4px 5px;}

Hope that helps,

Terry Arthur


I know this is an OLD topic, but I'm running into this same problem and was hoping someone could clarify a few things for me. 

I've followed the above directions, but am falling a little short on understanding the exact changes I need to make.  To use a custom "Add to Cart" button, do I upload that image to the same directory as 'backgrounds.png' and then just change out 'backgrounds.png' in line 50ish of 'vmsite-ltr.css' with the name of the custom image?


Thank you for any assistance that can be provided.

Title: Re: change add to cart button virtuemart 2.0
Post by: beanman1 on January 31, 2013, 18:10:07 PM
Well, I thought I understood how do to the next step, but obviously I'm a bit 'special' today.

I read through the thread on doing a template override, but I'm unsure on which folders to create and, in all honesty, where to create them.