Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Can somebody point me in the right direction wouldnt have a clue how to start programming this.

I want to filter post based on price (custom value) thru a widget. So lets say you click on a post category you get a list of all the posts in that category, but then I want to give the user the option to filter on price. Been searching for a widget that does this but havent found one.

share|improve this question
    
Do you want to sort the items based on price or just exclude ones that don't fit the criteria? –  fdsa Jul 14 '12 at 22:54
    
excluse those that dont fit the criteria, like once you go to a certain product category then you can filter on price, color, whatever all custom field value –  Bram Jul 15 '12 at 0:41
add comment

1 Answer

To search through the category, I think you would want to use get_posts to fetch all the posts in the particular category and then go through them with a for loop and check the custom value in each one and then echo the appropriate items to a results page.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.