• Hi there,

    with this loop -> [loop type=post category=art orderby=name order=ASC] I loop posts from a catagory ordered by name/ASC. In my case the name is always the name of an artist: “first-given-name” and “surname”. So the loop will order my posts by the first given names (of course) – but I need an order by surnames.

    Any idea how to order it by surnames?

    My idea: Because I don′t need to use taxonomies in my posts… maybe it is possible to loop all taxonomies (in my case: the surnames) and order them ASC?

    I′m sorry for my poor English!

    Thanks for your support & kindly regards,

    Bernd.

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • If “first-given-name” and “surname” are separate fields, try [loop type=post category=art orderby=field key=surname order=ASC]. If not, can you add a custom field to each entry for the surname and use that to orderby? The Advanced Custom Fields plugin makes it easy to add custom fields.

    Thread Starter BerndSpring

    (@berndspring)

    Thanks alot for your reply! firstname and surname aren′t separate fields, both are written in the title only. So you mean I should add a taxanomy to the posts called “surname” with the advanced custom fields plugin? How is the shortcode than called? [loop type=post category=art orderby=taxonomy key=surname order=ASC]?

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Loop posts ordered by “last name”, not name’ is closed to new replies.