無法回顯我想要的數組部分(使用get_comments()
WordPress函數)。我一直在閱讀有關,但似乎可以得到它的工作:回聲部分WP get_comments()數組
$args = array(
'meta_value' => 'tagline111'
);
echo get_comments($args[comment_content][0]);
,但我只是得到:"Array"
我已經試過所有可能的方法:將括號外放置內[]
引號,採用雙括號...
當我print_r(get_comments($args));
我有:
Array ([0] => stdClass Object ([comment_ID] => 8 [comment_post_ID] => 367
[comment_author] => pppaul [comment_author_email] => [email protected] [comment_author_url]
=> [comment_author_IP] => 127.0.0.1 [comment_date] => 2014-07-13 06:41:11
[comment_date_gmt] => 2014-07-13 06:41:11 [comment_content] => some content
[comment_karma] => 0 [comment_approved] => 1 [comment_agent] => Mozilla/5.0 (Windows
NT 6.1; WOW64; rv:30.0) Gecko/20100101 Firefox/30.0 [comment_type] => [comment_parent]
=> 0 [user_id] => 1 [meta_id] => 28 [comment_id] => 8 [meta_key] => referance2
[meta_value] => tagline111))
我在做什麼錯?
由於結果是對象。 – MH2K9