Pods - Custom Content Types and Fields
[resolved] Ordering by Alphabetical Order (3 posts)

  1. Joseph
    Posted 2 years ago #

    I created a CPT and called it Music, where I can create a place on my site for my client's discography. I included a field where I can upload an image, and then added a WYSIWYG editor to it.

    I created 3 different items, one for each of his albums. Then I used the shortcode to add each of his albums onto my Music Page.

    Question: Can I change the order that these albums are displayed in? It looks like it defaulted to alphabetical order according to the Title of each album.

    Link: http://www.josephruscitti.com/clients/jimmyclanton/jimmys-music/

    Thank you.


  2. Josh Pollock
    Plugin Contributor

    Posted 2 years ago #

    You need to add a "orderby" parameter to the shortcode.

    orderby = "title.meta_value ASC " should do it.

  3. Scott Kingsley Clark
    Plugin Author

    Posted 2 years ago #

    'orderby' => 't.post_title ASC' should actually do it in this case, assuming title isn't a custom field but the built-in Post Title field.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic