• I have set up a post custom field, called “schools” which contains school names.

    I am using WP Custom Search widget to search on the “Schools” field.

    In order to sequence the output I have amended the index.php with the following code prior to the loop to get the data displayed in alphabetical ascending (A-Z)

    query_posts($query_string . ‘&meta_key=School&orderby=meta_value’);

    It is giving me reverse alphabetical?

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Ordering posts by Custom Field’ is closed to new replies.