码迷,mamicode.com
首页 > 其他好文 > 详细

zencart产品属性dropmenu select只有一个选择项时自动变成radio单选的解决办法

时间:2014-09-22 13:36:22      阅读:185      评论:0      收藏:0      [点我收藏+]

标签:des   style   blog   color   io   ar   for   div   sp   

includes\modules\classic\attributes.php

在大约786行代码

case ($products_options->RecordCount() == 1):

 

的下面找到

$options_menu[] = zen_draw_radio_field(‘id[‘ . $products_options_names->fields[‘products_options_id‘] . ‘]‘, $products_options_value_id, ‘selected‘, ‘id="‘ . ‘attrib-‘ . $products_options_names->fields[‘products_options_id‘] . ‘-‘ . $products_options_value_id . ‘"‘) . ‘<label class="attribsRadioButton" for="‘ . ‘attrib-‘ . $products_options_names->fields[‘products_options_id‘] . ‘-‘ . $products_options_value_id . ‘">‘ . $products_options_details . ‘</label>‘ . "\n";

 

替换为

$options_menu[] = zen_draw_pull_down_menu(‘id[‘ . $products_options_names->fields[‘products_options_id‘] . ‘]‘, $products_options_array, $selected_attribute, ‘id="‘ . ‘attrib-‘ . $products_options_names->fields[‘products_options_id‘] . ‘"‘) . "\n";

 

即可。

zencart产品属性dropmenu select只有一个选择项时自动变成radio单选的解决办法

标签:des   style   blog   color   io   ar   for   div   sp   

原文地址:http://www.cnblogs.com/afish/p/3985589.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!