Magento-如何回显选定的产品属性(颜色)
我正在运行magento 1.4+ 在“产品视图”页面上,使用可配置的产品,如何获取所选属性以响应其标题 例如,我有彩色缩略图,当你点击它时,也会更新我的下拉列表。我只想回显文本onclick,而不是更改下拉列表。有什么建议吗?这是我的密码-Magento-如何回显选定的产品属性(颜色),magento,attributes,custom-attributes,thumbnails,Magento,Attributes,Custom Attributes,Thumbnails,我正在运行magento 1.4+ 在“产品视图”页面上,使用可配置的产品,如何获取所选属性以响应其标题 例如,我有彩色缩略图,当你点击它时,也会更新我的下拉列表。我只想回显文本onclick,而不是更改下拉列表。有什么建议吗?这是我的密码- <?php $_product = $this->getProduct(); $_attributes = Mage::helper('core')->decorateArray($this->getA
<?php
$_product = $this->getProduct();
$_attributes = Mage::helper('core')->decorateArray($this->getAllowAttributes());
?>
<?php if ($_product->isSaleable() && count($_attributes)):?>
<dl class="product-options-block">
<?php foreach($_attributes as $_attribute): ?>
<dt><label class="required"><?php echo $_attribute->getLabel() ?> <em>*</em></label></dt>
<dd<?php if ($_attribute->decoratedIsLast){?> class="last"<?php }?>>
<div class="input-box">
<select <?php if($this->showIcons()):?>style=""<?php endif;?> 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 style="clear:both;"></div>
</div>
</dd>
<?php endforeach; ?>
</dl>
<script type="text/javascript">
var spConfig = new Product.Config(<?php echo $this->getJsonConfig() ?>, '', optionsPrice, <?php echo $this->showIcons() ?>, '<?php echo $this->getIconsDir() ?>', '<?php echo $this->getIconExt() ?>', <?php echo $this->reloadeImage() ?>);
</script>
<?php endif;?>
*
class=“last”>
style=”“name=“super_attribute[]”id=“attribute”class=“required entry super attribute select”>
var spConfig=new Product.Config(,“”,optionsPrice,,“”);
从外观上看,您有一个非标准模板。你能发布一个网址吗?