Guest Posted January 28, 2009 Share Posted January 28, 2009 Hi everyone, Does anybody know if there is a way to display the manufacturer name below the product name on the product listing page? Currently it displays in a column next to the product name. Many thanks. Link to comment Share on other sites More sharing options...
juniorprg Posted January 28, 2009 Share Posted January 28, 2009 I havnt tested but something like this should work in catalog/modules/product_listing.php case 'PRODUCT_LIST_NAME': $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[$x]['products_id']) . '">' . $listing[$x]['products_name'] . '</a>'; $lc_text = ' ' . $listing[$x]['manufacturers_name'] . ' '; } else { $lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing[$x]['products_id']) . '">' . $listing[$x]['products_name'] . '</a> '; $lc_text = ' ' . $listing[$x]['manufacturers_name'] . ' '; if (PRODUCT_LIST_DESCRIPTION && $listing[$x]['products_description'] && PRODUCT_LIST_DESCRIPTION_MAX_LENGTH) $lc_text .= '<br><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td class="productDesc" align="center">' . tep_flatten_product_description($listing[$x]['products_description'], ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $listing[$x]['products_id']) . '"></a>') . '</td></tr></table>'; } dont copy this code since, i use a heavily modified site....here in this example you can see where i have made the changes $listing[$x] this may be different for you... also in my code i have made the description appear under the product name..hope this helps l8ter Link to comment Share on other sites More sharing options...
Guest Posted January 28, 2009 Share Posted January 28, 2009 I havnt tested but something like this should work in catalog/modules/product_listing.php dont copy this code since, i use a heavily modified site....here in this example you can see where i have made the changes $listing[$x] this may be different for you... also in my code i have made the description appear under the product name..hope this helps Hi juniorprg, I tried placing $lc_text = ' ' . $listing[$x]['manufacturers_name'] . ' '; into my code to get the following: case 'PRODUCT_LIST_NAME': $lc_align = ''; 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']) . '">' . $listing['products_name'] . '</a>'; $lc_text = ' ' . $listing[$x]['manufacturers_name'] . ' '; } else { $lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $listing['products_id']) . '">' . $listing['products_name'] . '</a> '; $lc_text = ' ' . $listing[$x]['manufacturers_name'] . ' '; } However the manufacturer now replaces the product name, does the above look correct to you? Thanks for your help i appreciate it. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.