shagg Posted January 23, 2006 Posted January 23, 2006 So this little project started with installing Option Type Feature (to great success) and following that up with Attrib Sort to make my life a little easier (supposedly). Well, there was a wee problem with that one - my attribs weren't being sorted properly. YMMV, but for my instance with these two mods working together, the following must be changed in product_info.php: //clr 030714 update query to pull option_type $products_options_name_query = tep_db_query("select distinct popt.products_options_id, popt.products_options_name, popt.products_options_type, popt.products_options_length, popt.products_options_comment from " . TABLE_PRODUCTS_OPTIONS . " popt, " . TABLE_PRODUCTS_ATTRIBUTES . " patrib where patrib.products_id='" . (int)$HTTP_GET_VARS['products_id'] . "' and patrib.options_id = popt.products_options_id and popt.language_id = '" . (int)$languages_id . "' order by popt.products_options_name"); needs to change to: //clr 030714 update query to pull option_type $products_options_name_query = tep_db_query("select distinct popt.products_options_id, popt.products_options_name, popt.products_options_type, popt.products_options_length, popt.products_options_comment from " . TABLE_PRODUCTS_OPTIONS . " popt, " . TABLE_PRODUCTS_ATTRIBUTES . " patrib where patrib.products_id='" . (int)$HTTP_GET_VARS['products_id'] . "' and patrib.options_id = popt.products_options_id and popt.language_id = '" . (int)$languages_id . "' order by patrib.attribute_sort"); The only difference is changing order by popt.products_options_name to patrib.attribute_sort to get it to work, otherwise, my list was coming up alphabetical instead of how I wanted it to look. Like I said, your mileage may vary, but this worked for me. Cheers, B. 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.