prettyswan Posted August 28, 2008 Share Posted August 28, 2008 the products is sorted by Product Name in admin pinewbjoy/products_attributes.php. i want to sort the products by ID. Can someboy help me how to do this? Link to comment Share on other sites More sharing options...
prettyswan Posted August 31, 2008 Author Share Posted August 31, 2008 anyone? Link to comment Share on other sites More sharing options...
sLaV- Posted August 31, 2008 Share Posted August 31, 2008 I think this will change the order in the attributes (PLEASE KEEP A BACKUP JUST IN CASE IT DOESNT WORK SO YOU CAN REVERT BACK TO OLD ONE!) in /catalog/admin/product_attributes.php around line 542 change this <?php $attributes = "select pa.* from " . TABLE_PRODUCTS_ATTRIBUTES . " pa left join " . TABLE_PRODUCTS_DESCRIPTION . " pd on pa.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' order by pd.products_name"; TO THIS: <?php $attributes = "select pa.* from " . TABLE_PRODUCTS_ATTRIBUTES . " pa left join " . TABLE_PRODUCTS_DESCRIPTION . " pd on pa.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' order by pd.products_id"; Havn't tested it as I dont have product attributes set up ... so please make backup before trying it Link to comment Share on other sites More sharing options...
prettyswan Posted August 31, 2008 Author Share Posted August 31, 2008 sLaV, thanks. it will save me lots of time. it almost works. but it still has some strange behaviors. can you figure it out? Link to comment Share on other sites More sharing options...
sLaV- Posted September 1, 2008 Share Posted September 1, 2008 sLaV, thanks. it will save me lots of time.it almost works. but it still has some strange behaviors. can you figure it out? Try <?php $attributes = "select pa.* from " . TABLE_PRODUCTS_ATTRIBUTES . " pa left join " . TABLE_PRODUCTS_DESCRIPTION . " pd on pa.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' order by pd.products_id DESC"; Link to comment Share on other sites More sharing options...
prettyswan Posted September 1, 2008 Author Share Posted September 1, 2008 hi, sLaV the problem is still there. maybe i should give up. the little bug will not waste me much time. thanks for your great help. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.