{"id":1600,"date":"2018-08-25T22:55:24","date_gmt":"2018-08-25T13:55:24","guid":{"rendered":"https:\/\/www.dogrow.net\/php\/?p=1600"},"modified":"2018-08-25T23:42:16","modified_gmt":"2018-08-25T14:42:16","slug":"blog50","status":"publish","type":"post","link":"https:\/\/www.dogrow.net\/php\/blog50\/","title":{"rendered":"(50) \u3010WORDPRESS\u3011\u6295\u7a3f\u8a18\u4e8b\u306e\u30ab\u30c6\u30b4\u30ea\u30fc\u3092\u53d6\u5f97"},"content":{"rendered":"<h1 class=\"my_h\">(1) \u3084\u308a\u305f\u3044\u3053\u3068<\/h1>\n<p>WORDPRESS\u3067\u306f\u306a\u3044\u5916\u90e8\u306e\u30d7\u30ed\u30b0\u30e9\u30e0\u304b\u3089\u3001<br \/>\nWORDPRESS\u6295\u7a3f\u8a18\u4e8b\u306e\u30ab\u30c6\u30b4\u30ea\u30fc\u540d\u3092\u53d6\u5f97\u3057\u305f\u3044\u3002<\/p>\n<h3 class=\"my_h\">\u524d\u63d0\u6761\u4ef6<\/h3>\n<p>\u6295\u7a3f\u8a18\u4e8b\u306e\u300cID\u300d\u304c\u308f\u304b\u3063\u3066\u3044\u308b\u3002<\/p>\n<h1 class=\"my_h\">(2) \u3084\u3063\u3066\u307f\u308b<\/h1>\n<p>\u30ab\u30c6\u30b4\u30ea\u30fc\u540d\u3092\u77e5\u308a\u305f\u3044\u6295\u7a3f\u8a18\u4e8b\u306eID\u3092 \u2605\u2605\u2605 \u3068\u3057\u3066\u4ee5\u4e0b\u306b\u8a18\u3059\u3002<\/p>\n<p>\u30ab\u30c6\u30b4\u30ea\u30fc\u540d\u306e\u60c5\u5831\u306f\u3001WORDPRESS\u304c\u4f7f\u7528\u3057\u3066\u3044\u308b\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306b\u4fdd\u5b58\u3055\u308c\u3066\u3044\u308b\u3002<br \/>\n\u5177\u4f53\u7684\u306b\u306f&#8230;<br \/>\n\u30fb<span class=\"my_fc_deeppink\">wp_terms<\/span> \u30c6\u30fc\u30d6\u30eb\u306b\u30ab\u30c6\u30b4\u30ea\u30fc\u540d\u304c\u4fdd\u5b58\u3055\u308c\u3066\u3044\u308b\u3002<br \/>\n\u30fb<span class=\"my_fc_deeppink\">wp_term_relationships<\/span> \u30c6\u30fc\u30d6\u30eb\u306b\u95a2\u9023\u4ed8\u3051\u3089\u308c\u3066\u3044\u308b\u6295\u7a3f\u8a18\u4e8b\u306eID\u304c\u4fdd\u5b58\u3055\u308c\u3066\u3044\u308b\u3002<\/p>\n<h3 class=\"my_h\">1. wp_term_relationships\u30c6\u30fc\u30d6\u30eb\u3067\u6295\u7a3f\u8a18\u4e8b\u306b\u95a2\u9023\u4ed8\u3051\u3089\u308c\u3066\u3044\u308b\u30ab\u30c6\u30b4\u30ea\u30fcID\u3092\u53d6\u5f97<\/h3>\n<p><span class=\"my_fc_deeppink\">wp_term_relationships<\/span> \u30c6\u30fc\u30d6\u30eb\u3067\u306f\u3001<span class=\"my_fc_deeppink\">object_id<\/span> \u306b\u6295\u7a3f\u8a18\u4e8b\u306e ID \u304c\u4fdd\u5b58\u3055\u308c\u3066\u3044\u308b\u3082\u306e\u3092\u63a2\u3059\u3002<br \/>\n\u305d\u3046\u3057\u3066\u5f97\u3089\u308c\u305f\u30ec\u30b3\u30fc\u30c9\u306e <span class=\"my_fc_deeppink\">term_taxonomy_id<\/span> \u306b\u30ab\u30c6\u30b4\u30ea\u30fcID\u304c\u683c\u7d0d\u3055\u308c\u3066\u3044\u308b\u3002<\/p>\n<p>\u3088\u3063\u3066&#8230;<br \/>\n\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u53d6\u5f97\u3067\u304d\u308b\u3002<\/p>\n<p>\u30fbSQL<\/p>\n<pre class=\"brush: sql; title: ; notranslate\" title=\"\">\r\nSELECT * FROM `wp_term_relationships` WHERE `object_id`='\u2605\u2605\u2605';\r\n<\/pre>\n<p>\u30fbPHP<\/p>\n<pre class=\"brush: php; title: ; notranslate\" title=\"\">\r\n$ID = $record&#x5B;'term_taxonomy_id'];\r\n<\/pre>\n<p>\u3053\u3053\u3067\u5f97\u3089\u308c\u305f\u30ab\u30c6\u30b4\u30ea\u30fcID\u3092 \u25b2\u25b2\u25b2 \u3068\u3057\u3066\u8a18\u3059\u3002<br \/>\n\u203b\u4e00\u3064\u306e\u6295\u7a3fID\u306b\u5bfe\u3057\u3066\u3001\u8907\u6570\u306e\u30ab\u30c6\u30b4\u30ea\u30fc\u304c\u95a2\u9023\u4ed8\u3051\u3089\u308c\u3066\u3044\u308b\u5834\u5408\u3082\u3042\u308b\u3002<br \/>\n\u3000\u3053\u306e\u5834\u5408\u3001\u4e0a\u8a18\u30af\u30a8\u30ea\u306b\u5bfe\u3057\u3066\u8907\u6570\u30ec\u30b3\u30fc\u30c9\u304c\u30d2\u30c3\u30c8\u3059\u308b\u3002<\/p>\n<h3 class=\"my_h\">2. wp_terms\u30c6\u30fc\u30d6\u30eb\u304b\u3089\u30ab\u30c6\u30b4\u30ea\u30fc\u60c5\u5831\u3092\u53d6\u5f97<\/h3>\n<p>\u4e0a\u8a18 1. \u3067\u5f97\u3089\u308c\u305fID\u3092\u30ad\u30fc\u306b\u3001<span class=\"my_fc_deeppink\">wp_terms<\/span> \u30c6\u30fc\u30d6\u30eb\u304b\u3089\u30ab\u30c6\u30b4\u30ea\u30fc\u540d\u3092\u53d6\u5f97\u3059\u308b\u3002<br \/>\n\u30fbSQL<\/p>\n<pre class=\"brush: sql; title: ; notranslate\" title=\"\">\r\nSELECT * FROM `wp_terms` WHERE `term_id`='\u25b2\u25b2\u25b2';\r\n<\/pre>\n<p>\u30fbPHP<\/p>\n<pre class=\"brush: php; title: ; notranslate\" title=\"\">\r\n$category_name = $record&#x5B;'name'];\r\n<\/pre>\n<p>\u3053\u308c\u3067\u30ab\u30c6\u30b4\u30ea\u30fc\u540d\u304c\u53d6\u5f97\u3067\u304d\u305f\u3002<\/p>\n<hr class=\"my_hr_bottom\">\n","protected":false},"excerpt":{"rendered":"<p>(1) \u3084\u308a\u305f\u3044\u3053\u3068 WORDPRESS\u3067\u306f\u306a\u3044\u5916\u90e8\u306e\u30d7\u30ed\u30b0\u30e9\u30e0\u304b\u3089\u3001 WORDPRESS\u6295\u7a3f\u8a18\u4e8b\u306e\u30ab\u30c6\u30b4\u30ea\u30fc\u540d\u3092\u53d6\u5f97\u3057\u305f\u3044\u3002 \u524d\u63d0\u6761\u4ef6 \u6295\u7a3f\u8a18\u4e8b\u306e\u300cID\u300d\u304c\u308f\u304b\u3063\u3066\u3044\u308b\u3002 (2) \u3084\u3063\u3066\u307f\u308b \u30ab\u30c6\u30b4\u30ea\u30fc\u540d\u3092\u77e5\u308a\u305f\u3044\u6295\u7a3f\u2026 <span class=\"read-more\"><a href=\"https:\/\/www.dogrow.net\/php\/blog50\/\">\u7d9a\u304d\u3092\u8aad\u3080 &raquo;<\/a><\/span><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[],"class_list":["post-1600","post","type-post","status-publish","format-standard","hentry","category-wordpress"],"views":1877,"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/posts\/1600","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/comments?post=1600"}],"version-history":[{"count":6,"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/posts\/1600\/revisions"}],"predecessor-version":[{"id":1609,"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/posts\/1600\/revisions\/1609"}],"wp:attachment":[{"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/media?parent=1600"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/categories?post=1600"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dogrow.net\/php\/wp-json\/wp\/v2\/tags?post=1600"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}