Originally Posted by
swguy
Ah you're right. OK. Take includes/modules/attributes.php and copy to includes/modules/YOUR_TEMPLATE/attributes.php.
Then go through that file. Everywhere you see the config flag I mentioned PRODUCT_IMAGES_ATTRIBUTES_NAMES
right before that you will see a call to zen_image. It's in 6 places.
Change those zen_image calls so that the second parameter to zen_image is $products_options->fields['products_options_values_name']
(this is the value which is shown when PRODUCT_IMAGES_ATTRIBUTES_NAMES = 1).
Sorry if I am misunderstanding here.
PHP Code:
$products_options->fields['products_options_values_name']
already exists. So where would I change it in the below?
PHP Code:
if (!empty($products_options->fields['attributes_image'])) { $tmp_attributes_image .= '<div class="custom-control custom-checkbox attribImg">' . zen_draw_checkbox_field('id[' . $products_options_id . ']['.$products_options_value_id.']', $products_options_value_id, $selected_attribute, 'id="' . $inputFieldId . '" ' . $data_properties . $field_disabled) . '<br>' . zen_image(DIR_WS_IMAGES . $products_options->fields['attributes_image']) . '<label class="custom-control-label attribsCheckbox" for="' . $inputFieldId . '">' . (PRODUCT_IMAGES_ATTRIBUTES_NAMES == '1' ? '<br>' . $products_options->fields['products_options_values_name'] : '') . (!empty($products_options_details_noname) ? '<br>' . $products_options_details_noname : '') . '</label></div>' . "\n"; } else { $tmp_attributes_image .= '<div class="custom-control custom-checkbox attribImg">' . zen_draw_checkbox_field('id[' . $products_options_id . ']['.$products_options_value_id.']', $products_options_value_id, $selected_attribute, 'id="' . $inputFieldId . '" ' . $data_properties . $field_disabled) . '<br />' . '<label class="custom-control-label attribsCheckbox" for="' . $inputFieldId . '">' . $products_options->fields['products_options_values_name'] . (!empty($products_options_details_noname) ? '<br>' . $products_options_details_noname : '') . '</label></div>' . "\n"; } break;
Bookmarks