I'm trying to order a
by
but wordpress doesn't seem to want to change the
The query is as follows
The resulting query is as follows
You should notice that the
value in the query has been set to
Even though I spesifically set it to
I've been reseting the query and post data all over the place to try and get the query to play nice by am now out of ideas.
Any help would be awesome
Ps: the query about is being called in a file that is
in the
which is inturn called using the
wordpress function
Code:
WP_query
Code:
meta_value
Code:
orderby
The query is as follows
Code:
$popular_args = array(
'post_type' => 'post',
'post_status' => 'publish',
'posts_per_page' => -1,
'meta_key' => 'wpb_post_views_count',
'orderby' => 'meta_value_num',
'order' => 'ASC',
);
$popular_query = new WP_query( $popular_args );
The resulting query is as follows
Code:
WP_Query Object ( [query_vars] => Array (
[post_type] => post
[post_status] => publish
[posts_per_page] => -1
[meta_key] => wpb_post_views_count
[orderby] => menu_order
[order] => ASC
[error] =>
[m] =>
[p] => 0
[post_parent] =>
[subpost] =>
....
You should notice that the
Code:
orderby
Code:
menu_order
Even though I spesifically set it to
Code:
meta_value_num
I've been reseting the query and post data all over the place to try and get the query to play nice by am now out of ideas.
Any help would be awesome
Ps: the query about is being called in a file that is
Code:
required
Code:
sidebar
Code:
get_sidebar()