order meta_key alphabetically
-
hello all,
i had my code working, then something stopped working…
global $wp_query;
$args = array(
‘meta_key’ => ‘dealer_state’, //custom field
‘orderby’ => ‘meta_value’,
‘order’ => ‘ASC’
);
query_posts(array_merge( $wp_query->query,$args ));this used to alphabetize the states, but it’s not working any more. thoughts anyone?
thank in advance
td
- The topic ‘order meta_key alphabetically’ is closed to new replies.