WordPress.org

Ready to get started?Download WordPress

Forums

Allowing visitors to sort posts by date, category and title (5 posts)

  1. Tyler_Murphy
    Member
    Posted 3 years ago #

    I have a blog that displays the latest posts from multiple categories. I have been searching for a way to allow visitors to my site to choose to sort my posts by the date posted, title or category. So far the only option I have found is the smart sort premium plugin which is no longer available for sale.

    Does anyone know of a good alternative or a way to do this (preferably plugin based - I'm no php expert!)

    Any help would be massively appreciated.

  2. whalesharkwebsites
    Member
    Posted 3 years ago #

    There's a useful article about sorting posts alphabetically - not a plugin, but the code looks to be pretty copy & paste:

    http://codex.wordpress.org/Alphabetizing_Posts

  3. Tyler_Murphy
    Member
    Posted 3 years ago #

    Thanks whalesharkwebsites - unfortunately it needs to be a bit moer advanced than that.

  4. Tyler_Murphy
    Member
    Posted 3 years ago #

    Any body have any ideas?

  5. zoen
    Member
    Posted 3 years ago #

    Did you manage to get any further with this?

    I also need to do the same thing, I would like to let a visitor sort the posts by title, date or a custom field by selecting the sort type from a dropdown list on the webpage. I can't seem to find anything that helps much. I know you can use the orderby in the query_posts in the template. but how do you get the users selection in the query_posts and then the resulting update of the webpage after selection, is where I am stuck.

    Can anybody help with this?

Topic Closed

This topic has been closed to new replies.

About this Topic