radders, on Dec 27 2003, 01:38 PM, said:
I would love to have the possibilty of a tiny thumbnail image appearing in product info in each slave product listing.
Uhmm...admin > Configuration > Slave Products > Display Slave Product Image? Or do you just want to modify the size of this image? To modify the size, change (around lines 150-7 of includes/modules/master_listing.php)
case 'MASTER_LIST_IMAGE':
$lc_align = 'center';
if (isset($HTTP_GET_VARS['manufacturers_id'])) {
$lc_text = '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id=' . $HTTP_GET_VARS['manufacturers_id'] . '&products_id=' . $listing['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a>';
} else {
$lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a> ';
}
break;to
case 'MASTER_LIST_IMAGE':
$lc_align = 'center';
if (isset($HTTP_GET_VARS['manufacturers_id'])) {
$lc_text = '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id=' . $HTTP_GET_VARS['manufacturers_id'] . '&products_id=' . $listing['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing['products_image'], $listing['products_name'], SLAVE_IMAGE_WIDTH, SLAVE_IMAGE_HEIGHT) . '</a>';
} else {
$lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $listing['products_image'], $listing['products_name'], SLAVE_IMAGE_WIDTH, SLAVE_IMAGE_HEIGHT) . '</a> ';
}
break;and run the following SQL
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) VALUES ('Slave Image Width', 'SLAVE_IMAGE_WIDTH', '100', 'The pixel width of images in the slave listings', '4', '0', now());
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) VALUES ('Slave Image Height', 'SLAVE_IMAGE_HEIGHT', '80', 'The pixel height of images in the slave listings', '4', '0', now());Now the slave listing image size will be set separately in admin > Configuration > Images. Change sort order numbers as works for you.
Hth,
Matt