Remove a "sort by" option?

I’d like to change the sort options, removing the “popularity” option, as it seems to be pretty much the same as the “Bestselling” option.



I’ve dug through the back end, the tpl files and even the DB and I can’t seem to find where this is being set. I can see that the sorting.tpl file loops through the $sorting variable and for each $option it displays it. To save my life, I can’t find where that variable is assigned or those options are set.



Little help?

Better yet, how can we remove everything?

/skins/[your skin]/customer/views/products/components/sorting.tpl



then I just commented out the entire file with[COLOR=Red] {*[/COLOR] and ending in [COLOR=Red]*}[/COLOR]

I’ve searched for over an hour and I can’t find how to remove some of the sort by options and re-order them. Anyone know how?



Thanks.

I figured it out! In fn.catalog.php do a search for $sorting = array and comment out the options you don’t want and you can rearrange the order. See below



$sorting = array(
//'position' => array('description' => fn_get_lang_var('default'), 'default_order' => 'asc'),
'product' => array('description' => fn_get_lang_var('name'), 'default_order' => 'asc'),
'price' => array('description' => fn_get_lang_var('price'), 'default_order' => 'asc'),
//'popularity' => array('description' => fn_get_lang_var('popularity'), 'default_order' => 'desc')
);

Old post I know but I am trying to remove completely the "sort by price" and number of "products per page" ability from store front

Can it be done

John

Old post I know but I am trying to remove completely the "sort by price" and number of "products per page" ability from store front

Can it be done

John

I believe this can be changed in Settings > Appearance > Available product list sortings.

yes it can, https://prnt.sc/j3xnhh

But even when I remove the tick and save it still reappears checked. I was hoping I could alter the code so it doesnt even show for customers to choose in the store front.

John

yes it can, https://prnt.sc/j3xnhh

But even when I remove the tick and save it still reappears checked. I was hoping I could alter the code so it doesnt even show for customers to choose in the store front.

John

Comment out the views/products/components/sorting.tpl file (in the file itself), havent tested it but that should do the job.

Perhaps add this to the bugtracker. I think you should be able to remove the sorting completely. I dont know CS-Cart's opinion on this though.

Thanks Will do

Just add the following code to the CSS section of the Theme editor

.ty-sort-dropdown {
    display: none !important;
}

Just add the following code to the CSS section of the Theme editor

.ty-sort-dropdown {
    display: none !important;
}

works ....

Many thanks