hi all,
I'm trying to clean up my product layout pages at the moment. My custom fields selection is a messy. Im using an image custom fields selection. The radio buttons and individual thumbs are not aligned I would like to put each selection into its own column.
Where can I do this?
stef
Hello,
Common practice is to create overrides.
1. Check css; chances are, that you don't need layout overrides, just edit your css.
2. Copy files from your_site\components\com_virtuemart\views\productdetails\tmpl to your_site\templates\your_template\html\com_virtuemart\productdetails
3. Modify whateveryouwish in those copied files (perhaps, two files to start with are default.php and default_customfields.php).
4. If you want to distinct your new override from default layout, rename your default.php into some_new_name.php. Don't forget to assign it to certain products in VM product settings.
This thread may help you: http://forum.virtuemart.net/index.php?topic=92756.0 (http://forum.virtuemart.net/index.php?topic=92756.0)
Regards
SamF Thanks the the advice.
I will look into the css but I'm not sure how to deal with it as they each have the same id and name!
This is the current html output:
span class="product-field-display">
<input id="6" type="radio" name="customPrice[0][6]" value="7" checked="checked">
<label for="6">
<img alt="btc_fuchsia" src="/images/stories/virtuemart/product/resized/btc_fuchsia.jpg">
</label>
<input id="6" type="radio" name="customPrice[0][6]" value="8">
<label for="6">
<input id="6" type="radio" name="customPrice[0][6]" value="9">
<label for="6">
</span>
So i had thought about wrapping each in a span
span class="product-field-display">
<span class="pfd-column">
<input id="6" type="radio" name="customPrice[0][6]" value="7" checked="checked">
<label for="6">
<img alt="btc_fuchsia" src="/images/stories/virtuemart/product/resized/btc_fuchsia.jpg">
</label>
</span>
....
</span>
So i looked in defaultcustomfield.php and the line I'm concern with is 38:
<span class="product-field-display"><?php echo $field->display ?></span>
I can't locate where the $feild->display is generated so I cannot wrap them individually.
Thanks again