{"id":205808,"date":"2015-05-26T18:37:40","date_gmt":"2015-05-26T09:37:40","guid":{"rendered":""},"modified":"2016-07-30T21:09:17","modified_gmt":"2016-07-30T21:09:17","slug":"%e8%a4%87%e6%95%b0%e8%91%97%e8%80%85%e3%82%92%e3%82%bb%e3%83%83%e3%83%88%e3%81%a7%e3%81%8d%e3%82%8bco-authors-plus%e3%81%a7%e3%81%aeprimary-author%e4%bb%a5%e5%a4%96%e3%81%ae%e8%a8%98%e4%ba%8b%e8%a1%a8","status":"closed","type":"topic","link":"https:\/\/ja.wordpress.org\/support\/topic\/%e8%a4%87%e6%95%b0%e8%91%97%e8%80%85%e3%82%92%e3%82%bb%e3%83%83%e3%83%88%e3%81%a7%e3%81%8d%e3%82%8bco-authors-plus%e3%81%a7%e3%81%aeprimary-author%e4%bb%a5%e5%a4%96%e3%81%ae%e8%a8%98%e4%ba%8b%e8%a1%a8\/","title":{"rendered":"\u8907\u6570\u8457\u8005\u3092\u30bb\u30c3\u30c8\u3067\u304d\u308bCo Authors Plus\u3067\u306ePrimary Author\u4ee5\u5916\u306e\u8a18\u4e8b\u8868\u793a"},"content":{"rendered":"<p>\u5171\u8457\u8005\u304c\u3044\u308b\u5834\u5408\u306b\u8907\u6570\u8457\u8005\u3092\u30bb\u30c3\u30c8\u3067\u304d\u308bCo Authors Plus\u3068\u3044\u3046\u30d7\u30e9\u30b0\u30a4\u30f3\u3092\u4f7f\u3063\u3066\u3044\u308b\u306e\u3067\u3059\u304c\u3001<br \/>\n<a href=\"https:\/\/wordpress.org\/plugins\/co-authors-plus\/\">https:\/\/wordpress.org\/plugins\/co-authors-plus\/<\/a><\/p>\n<p>\u8a18\u4e8b\u306f\u7121\u4e8b\u306b\u5171\u8457\u8005\u3092\u8868\u793a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u305f\u306e\u3067\u3059\u304c\u3001\u5225\u3067\u8457\u8005\u4e00\u89a7\u30da\u30fc\u30b8\u3092\u4f5c\u3063\u3066\u3044\u3066\u3001\u8457\u8005\u306e\u30d7\u30ed\u30d5\u30a3\u30fc\u30eb\u306e\u4e0b\u306b\u5404\u8457\u8005\u306e\u6700\u65b0\u8a18\u4e8b3\u4ef6\u3092\u8868\u793a\u3057\u3066\u3044\u307e\u3059\u3002<br \/>\n\u305d\u306e\u3068\u304d\u3001Co Authors Plus\u3067Primary Author\uff08\u6700\u521d\u306e\u8457\u8005\uff09\u306b\u8a2d\u5b9a\u3055\u308c\u3066\u3044\u306a\u3044\u8a18\u4e8b\u304c\u547c\u3073\u51fa\u305b\u306a\u3044\u3053\u3068\u306b\u6c17\u3065\u304d\u307e\u3057\u305f\u3002<\/p>\n<pre><code>&lt;?php\n\t$users =get_users( array(&#039;orderby&#039;=&gt;display_name,&#039;order&#039;=&gt;ASC,&#039;exclude&#039; =&gt; array(1),) ); \/\/admin\u3092\u9664\u5916\n\tforeach($users as $user):\n    $uid = $user-&gt;ID;\n    $userData = get_userdata($uid);\n\t$user_post_count = count_user_posts($uid);\n\t ?&gt;<\/code><\/pre>\n<p>\u3068\u3084\u3063\u3066\u3044\u3066$user_post_count\u3067\u306f\u5171\u8457\u5206\u3082\u30ab\u30a6\u30f3\u30c8\u3055\u308c\u305f\u6570\u5b57\u306b\u306a\u308b\u306e\u3067\u3059\u304c<\/p>\n<p><code>&lt;?php $posts = get_posts(&quot;author=$user-&gt;ID&amp;orderby=date&amp;post_type=post&amp;posts_per_page=3&quot;); ?&gt;<\/code><\/p>\n<p>\u3067\u547c\u3073\u51fa\u3057\u3066\u3044\u308b\u6700\u65b03\u4ef6\u306e\u60c5\u5831\u306fPrimary Author\u306b\u8a2d\u5b9a\u3055\u308c\u3066\u3044\u306a\u3044\u3082\u306e\u304c\u8868\u793a\u3055\u308c\u306a\u3044\u72b6\u614b\u3067\u3059\u3002<\/p>\n<p>github\u3067\u60c5\u5831\u3092\u898b\u305f\u3089Author\u3067\u547c\u3073\u51fa\u305b\u308b\u306e\u304cPrimary Author\u306e\u307f\u3063\u307d\u3044\u3053\u3068\u306f\u5206\u304b\u3063\u305f\u306e\u3067\u3059\u304c\u3001<br \/>\n<a href=\"https:\/\/github.com\/fusioneng\/Co-Authors-Plus-Roles\/blob\/master\/PROJECT.md\">https:\/\/github.com\/fusioneng\/Co-Authors-Plus-Roles\/blob\/master\/PROJECT.md<\/a><\/p>\n<blockquote>\n<p>All of this data should be exposed in the WP_Query API, so that queries like:<\/p>\n<\/blockquote>\n<p>\u306e\u3068\u3053\u308d\u306b\u66f8\u3044\u3066\u3042\u308b&#8217;role&#8217;\u3092\u8a2d\u5b9a\u3059\u308c\u3070Primary Author\u4ee5\u5916\u3082\u547c\u3073\u51fa\u305b\u308b\u306e\u304b\uff1f<br \/>\n\u3044\u308d\u3044\u308d\u8a66\u3057\u3066\u307f\u305f\u306e\u3067\u3059\u304c\u3001\u4e0a\u624b\u304f\u3044\u304b\u306a\u3044\u306e\u3067\u3082\u3057\u5206\u304b\u308b\u65b9\u304c\u3044\u3089\u3063\u3057\u3083\u3044\u307e\u3057\u305f\u3089\u6559\u3048\u3066\u9802\u3051\u306a\u3044\u3067\u3057\u3087\u3046\u304b\u3002<\/p>\n<p>&lt;?php $posts = get_posts(&#8220;author=$user-&gt;ID&amp;orderby=date&amp;post_type=post&amp;posts_per_page=3&#8221;); ?&gt;<br \/>\n\u306e$user-&gt;ID\u3092$coauthor-&gt;ID\u306b\u3057\u3066\u3057\u307e\u3046\u3068\u8a72\u5f53\u306e\u8457\u8005\u306e$coauthor\u3060\u3051\u3067\u306f\u306a\u304f\u5168\u4f53\u306e$coauthor\u304c\u547c\u3073\u51fa\u3055\u308c\u3066\u3057\u307e\u3046\u3088\u3046\u3067\u4e0a\u624b\u304f\u3044\u304d\u307e\u305b\u3093\u3067\u3057\u305f\u2026<\/p>\n<p>\u3069\u3046\u305e\u5b9c\u3057\u304f\u304a\u9858\u3044\u81f4\u3057\u307e\u3059\u3002<\/p>\n","protected":false},"template":"","class_list":["post-205808","topic","type-topic","status-closed","hentry","topic-tag-co-authors-plus","topic-tag-25064","topic-tag-secondary-authors"],"jetpack_sharing_enabled":true,"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/ja.wordpress.org\/support\/wp-json\/wp\/v2\/topic\/205808","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ja.wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/ja.wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/ja.wordpress.org\/support\/wp-json\/wp\/v2\/topic\/205808\/revisions"}],"wp:attachment":[{"href":"https:\/\/ja.wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=205808"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}