Filtering and Sorting Specials

By | July 4, 2012

Late last night I came across an interesting post from Carine, where the need is for filtering and sorting of the special offers. I’m intrigued to see what Carine comes up with…

In the meantime, I decided to code up something very quick and dirty on the specials page only. I chose the easiest options and came up with a way to filter on;

– manufacturer
– % of the discount

and sort on;

– amount of the discount

In addition I wanted to ensure that selected sort/filter is maintained even if another sort/filter is chosen. In this way I can say (for example) “show me discounts above 25% on products by Microsoft, sorted from high to low”. This makes the specials very easy to find, and would be useful for those shops who have many special offers running at one time.

There’s no limit to how many filters/sorts can be run at one time, as all the filters/sorts do is change the SQL command that grabs the products from the database.

Here’s an example video, showing some sorting and filtering;

Some more examples (would just need a link added, and some extra SQL);

– filter specials to show all DVDs on special offer
– filter specials to show all DVDs only from Warner that are more than 50% discounted
– sort specials by original price

I’m sure that we can think of many more. And all are possible, why not?


A good idea by Carine, and useful for allow potential clients to drill down through your special offers to find what they are looking for faster. Which can only be a good thing.

Leave a Reply

Your email address will not be published.