如何在wp_query wordpress函数中创建一个循环?

时间:2016-01-01 13:27:21

标签: arrays wordpress loops wp-query

我想在循环中使用print数组,并希望将其放在wp_query中。可能吗? 如果还有其他选择,请提及它。

$wp_user_query = new WP_User_Query(array('role' => 'Subscriber', 'fields' => 'all',
'meta_query' => array(
    'relation' => 'OR',
    // Here I want to create a loop
    // loop will start from here repeating the array
    array(
    'key'       => 'user_group_name',
    'value'     => 'Panera Group 2 Encino',
    'compare'   => 'LIKE'
    ),
    // loop end
    /*array(
    'key'       => 'user_group_name',
    'value'     => 'West Hollywood',
    'compare'   => 'LIKE'
    ),*/
)));

0 个答案:

没有答案