VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: ryanmccoy on May 05, 2012, 23:48:06 PM

Title: Custom Field layout position for cart
Post by: ryanmccoy on May 05, 2012, 23:48:06 PM
Is it possible to control the layout of the custom fields in the cart?  All my fields are in one line.  I need a line break inbetween fields otherwise it all runs together. 
Title: Re: Custom Field layout position for cart
Post by: jenkinhill on May 06, 2012, 23:54:18 PM
Use Firebug to examine the elements on the page. That should indicate the css & code being used and allow you to test some style edits.

http://forum.virtuemart.net/index.php?topic=73348.0

Alternatively use Firebug Lite with Developer Tools in Chrome. https://developers.google.com/chrome-developer-tools/docs/overview
Title: Re: Custom Field layout position for cart
Post by: cristina on May 07, 2012, 12:31:45 PM
Hi there,
I'm developing a site using VM 2.0.6 and I have a simple question (I hope it's simple)

I have configured a VM Custom stockable variant and it works fine.
The only thing I would like to change is the way the field is displayed in the cart.

If I look at the product details I correctly see the variant "Option Name" and the select list of available options (see the attached Product Detail), while in the cart it shows the "Title" of the variant instead of the "Option name" (see Cart.png).

I would like first to change the Title with the Option Name and then change the position of the elements in the cart.

Unfortunately the Custom filed is surrounded with many <div> and <span> without a class or id, so it seems that I need to modify some view or, worse, some other part.

Can someone tell me what I need to modify to obtain the result I want?

I already spent a day looking into the various files, but I did non figure out which one is responsible of formatting the custom field in the cart view.

Thanks a lot

Cristina

[attachment cleanup by admin]
Title: Re: Custom Field layout position for cart
Post by: Ziggo on May 08, 2012, 14:51:39 PM
I've the same problem. Does anyone fount a solution?

Greetings
Title: Re: Custom Field layout position for cart
Post by: ryanmccoy on May 13, 2012, 21:08:34 PM
I added this to vmsite-ltr.css


div.vm-customfield-mod span.product-field-type-V {
   display: inline-block;
   position: relative;
   clear: left;
}

div.vm-customfield-cart span.product-field-type-V {
   display: inline-block;
   position: relative;
   float: left;
   clear: left;
}
Title: Re: Custom Field layout position for cart
Post by: monkeybutt on June 14, 2012, 00:01:26 AM
I'm having a somewhat similar problem. My custom field labels were on one line and my custom field values were on a separate line (in both the cart and mod). I used the above CSS but only my custom field labels ended up on separate lines. The user-input data was still below and on one line. Looking at the code, it appears the data is in a completely separate div. Anyone have any idea how to remedy (using Joomla 2.5 and VM 2.0.6)

[attachment cleanup by admin]