- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-21-2016
02:29 PM
08-21-2016
02:29 PM
I have configurable items, and the underlaying simple products only have one color. (and many sizes)
How can i fix that the costumer don't have to choose the only color available, but (programmaticly) only have to choose the size.
And yes this will be for all the configurable items on the shop! (so an shopping item only has one color and many sizes)
(And no it didn't work to create a new attribute set, I already tried)
Solved! Go to Solution.
Labels:
1 ACCEPTED SOLUTION
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-28-2016
02:07 PM
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-21-2016
11:51 PM
08-21-2016
11:51 PM
Re: Show only sizes
Hi.
Add conidition in configurable.phtml file. Change attribute id as per your need
app/design/frontend/your_package/your_theme/template/catalog/product/view/type/options/configurable.phtml
if (!$_rendered): ?> <?php if($_attribute->getAttributeId() != 'Your_Attribute_Id') {?> <dt><label class="required"><em>*</em><?php echo $_attribute->getLabel() ?></label></dt> <dd<?php if ($_attribute->decoratedIsLast){?> class="last"<?php }?>> <div class="input-box123"> <select name="super_attribute[<?php echo $_attribute->getAttributeId() ?>]" id="attribute<?php echo $_attribute->getAttributeId() ?>" class="required-entry super-attribute-select"> <option><?php echo $this->__('Choose an Option...') ?></option> </select> </div> </dd> <?php }else{?> <select name="super_attribute[Your_attribute_id]" id="attribute{Your_attribute_id}" style="display:none"> <option value="26" price="0" data-label="red" selected>Red</option> </select> <?php }?> <?php endif; ?>
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-28-2016
02:07 PM