0
私はこの1つで少し失われています。タクソノミーとカスタムポストタイプの注文
注文分類を無視して、投稿された日付順に投稿を表示していますが、私は99%の仕事を持っているカスタム分類のインデックスページを作成しようとしています。
$number_of_posts = intval(get_option('theme_number_posts_agent'));
$get_county = get_terms(
'new_developments',
array(
'orderby' => 'name',
'order' => 'ASC',
'hide_empty' => 1,
)
);
if(!$number_of_posts){
$number_of_posts = 3;
}
foreach ($get_county as $get_countys) {
$agents_query = array(
'post_type' => 'agent',
'posts_per_page' => $number_of_posts,
'paged' => $paged,
'orderby' => 'title', 'order' => 'ASC',
'tax_query' => array(
array(
'taxonomy' => 'new_developments',
'field' => 'slug',
'terms' => $get_countys
)
)
);
$agent_listing_query = new WP_Query($agents_query);
if ($agent_listing_query->have_posts()) :
while ($agent_listing_query->have_posts()) :
$agent_listing_query->the_post();
私は
... get_terms下とwp_query何もして2箇所にorderbyの置かれているすべてのヘルプは大
ありがとう? http://wordpress.stackexchange.com/questions/14306/using-wp-query-is-it-possible-to-orderby-taxonomy – Benoti
hmmm okは、私がそれと一緒に作業しているものが完璧であるように少しばかげているようです – Aaron