WordPress.org

Ready to get started?Download WordPress

Forums

Flexo Archives
[resolved] Month sort order (6 posts)

  1. Adrian
    Member
    Posted 3 years ago #

    I love it!

    Question about the sort order:
    It seems counter-intuitive that the years are listed with the most recent at the top, but when you expand a year, the months are listed starting with January.

    Wouldn't it be more consistent to start with the most recent first?
    ie for 2011, list months in the order March, Feb, Jan

    Thanks

    Adrian

    http://wordpress.org/extend/plugins/flexo-archives-widget/

  2. Heath Harrelson
    Member
    Plugin Author

    Posted 3 years ago #

    I can understand what you mean, but it's never struck me as odd. Also, no one else has ever raised the issue in the four years that the plugin has been out there. I'm reluctant to add another option to the plugin unless several users request it.

    If it really bothers you, it's very simple to change the behavior. Just alter line 516 of the query_archives() function to end with "DESC" instead of "ASC." That is, change this:

    ORDER BY YEAR(post_date) DESC, MONTH(post_date) ASC

    to this:

    ORDER BY YEAR(post_date) DESC, MONTH(post_date) DESC

    Unfortunately, this will get undone every time the plugin updates, and you'll have to make the change again.

  3. Heath Harrelson
    Member
    Plugin Author

    Posted 3 years ago #

    Actually, I wouldn't want you to have to make the change described above over and over, and it's such a simple change that I think I'll go ahead and add an option for this. If I add it to the global options section of the options page, it won't be cluttering things up.

    I probably won't get around to adding the option until next week, so look for the update to come around then.

  4. Adrian
    Member
    Posted 3 years ago #

    Many thanks - that would be great

  5. Heath Harrelson
    Member
    Plugin Author

    Posted 3 years ago #

    I have implemented this feature. Before I do a release, please try the development version and let me know what you think.

    You'll find the setting by expanding the "Settings" menu on the Dashboard and choosing the "Flexo Archives" item. The checkbox for the setting is in the global options section.

  6. Adrian
    Member
    Posted 3 years ago #

    that works fine.
    Thanks

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic