shahin Posted September 6, 2005 Posted September 6, 2005 Hi, I want to show product description at product listing page. I have seen some contributions about how to add a short description at product listing page.All of those contributions involved some modification of the database structure. But I don't want to change the database structure. Could anybody tell me how can I add a description at the product listing page without modifying database structure! Thanks in advance Shahin Quote
wheeloftime Posted September 6, 2005 Posted September 6, 2005 Hi, I want to show product description at product listing page. I have seen some contributions about how to add a short description at product listing page.All of those contributions involved some modification of the database structure. But I don't want to change the database structure. Could anybody tell me how can I add a description at the product listing page without modifying database structure! Thanks in advance Shahin <{POST_SNAPBACK}> That depends. If you want to show something different from your normal product description you are stuck to something new. If a part from the orignal product description would do then you can just add that underneath the product name in your product listing. You can see a very rudimentary example on my shop as I kept it simple and just show the first 60 characters from the normal product description without checking for line breaks, if I am in the middle of a word or anything. Look in your catalag/modules/product_listing.php for 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> <br><br> ' . substr($listing['products_description'],0,60) . '...'; } else { $lc_text = ' <a href="' . tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath=' . $cPath . '&' : '') . 'products_id=' . $listing['products_id']) . '">' . $listing['products_name'] . '</a> <br><br> ' . substr($listing['products_description'],0,60) . '...'; } break; Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.