WordPress.org

Ready to get started?Download WordPress

Forums

Display Posts Shortcode
Not Ordering by Custom Field? (1 post)

  1. sheabaker
    Member
    Posted 8 months ago #

    We added a "weight" field to a custom post type so that we could manually set the order that the lists displayed by the short code would work. However, it does not seem to be registering it and is defaulting to another ordering system.

    An earlier post showed stated that you could order by a custom field and just used it in the orderby argument. But that is not working for me.

    We are using "Advanced Custom Fields 4.2.2" to generate the custom post type fields.
    The field name is "weight" and the short code we tried is:
    [display-posts post_type="program" taxonomy="program_taxonomy" tax_term="3-hockey" order="ASC" orderby="weight" posts_per_page="-1"]

    What are we missing?
    Thank you.

    http://wordpress.org/plugins/display-posts-shortcode/

Reply

You must log in to post.

About this Plugin

About this Topic