Guest Alirat Posted August 4, 2011 Share Posted August 4, 2011 When customers browse for products they are not automatically coming up alphabetically. Is there any way to make this the default behaviour? Quote Link to comment Share on other sites More sharing options...
leeofaccy Posted August 4, 2011 Share Posted August 4, 2011 Hi First, in General Settings, under the styles & Misc tab, set Display newest products first to No. Next, open includes/content/viewCat.inc.php and find this block of code (around line 95)... $orderSort = sprintf(' ORDER BY %s %s', $_GET['sort_by'], $orderType); } else { if ($config['cat_newest_first']) { $orderSort = sprintf(' ORDER BY `date_added` DESC, `name` ASC'); } else { $orderSort = false; } } Change it to.... $orderSort = sprintf(' ORDER BY %s %s', $_GET['sort_by'], $orderType); } else { if ($config['cat_newest_first']) { $orderSort = sprintf(' ORDER BY `date_added` DESC, `name` ASC'); } else { $orderSort = sprintf(' ORDER BY `name` ASC'); } } Lee Quote Link to comment Share on other sites More sharing options...
Guest Alirat Posted August 4, 2011 Share Posted August 4, 2011 Thanks I'll give that a try. Quote Link to comment Share on other sites More sharing options...
Guest Alirat Posted August 8, 2011 Share Posted August 8, 2011 Hi First, in General Settings, under the styles & Misc tab, set Display newest products first to No. Next, open includes/content/viewCat.inc.php and find this block of code (around line 95)... $orderSort = sprintf(' ORDER BY %s %s', $_GET['sort_by'], $orderType); } else { if ($config['cat_newest_first']) { $orderSort = sprintf(' ORDER BY `date_added` DESC, `name` ASC'); } else { $orderSort = false; } } Change it to.... $orderSort = sprintf(' ORDER BY %s %s', $_GET['sort_by'], $orderType); } else { if ($config['cat_newest_first']) { $orderSort = sprintf(' ORDER BY `date_added` DESC, `name` ASC'); } else { $orderSort = sprintf(' ORDER BY `name` ASC'); } } Lee Thanks Lee that worked just dandy! Quote Link to comment Share on other sites More sharing options...
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.