WordPress.org

Ready to get started?Download WordPress

Forums

List category posts
Order list by custom field (9 posts)

  1. danicasati
    Member
    Posted 8 months ago #

    Hi.
    This could be a must-have feature:

    It is possible to order by CUSTOM FIELD?

    http://wordpress.org/plugins/list-category-posts/

  2. picandocodigo
    Member
    Plugin Author

    Posted 8 months ago #

    It would be possible. From what I read in the documentation it would be possible. I'll check it out and see if I can add it to the next version.

  3. danicasati
    Member
    Posted 8 months ago #

    Thnak you very much.
    Many users will search for this feature.

  4. picandocodigo
    Member
    Plugin Author

    Posted 8 months ago #

    A first implementation was done for version 0.35:

    customfield_orderby - You can order the posts by a custom field. For example: [catlist numberposts=-1 customfield_orderby=Mood order=desc] will list all the posts with a "Mood" custom field. Remember the default order is descending, more on order:

    Please test and let me know what you think :)

  5. danicasati
    Member
    Posted 8 months ago #

    It seems it works...
    You rock!

  6. danicasati
    Member
    Posted 8 months ago #

    I'm testing this function, doesn't work if "post_status=draft".

  7. picandocodigo
    Member
    Plugin Author

    Posted 8 months ago #

    That's weird, what other parameters are you using?

    I tried it with this on my dev blog:
    [catlist numberposts=-1 customfield_orderby=Mood post_status=draft order=desc]
    And it does work (also altering between "desc" and "asc" order changes).

  8. danicasati
    Member
    Posted 8 months ago #

    I'm using two shortcodes in the same post, it works in one, but adding post_status=draft it doesn't work for me.
    Can I send URL in PM?

  9. picandocodigo
    Member
    Plugin Author

    Posted 8 months ago #

    Yes, or contact me here:
    http://picandocodigo.net/contact

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.