{"id":1792,"date":"2012-02-15T12:39:57","date_gmt":"2012-02-15T03:39:57","guid":{"rendered":"http:\/\/stocker.jp\/diary\/?p=1792"},"modified":"2012-02-16T01:57:30","modified_gmt":"2012-02-15T16:57:30","slug":"php-hatena-bookmark","status":"publish","type":"post","link":"https:\/\/stocker.jp\/diary\/php-hatena-bookmark\/","title":{"rendered":"PHP\u3067\u81ea\u5206\u306e\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u3092\u6574\u5f62\u3057\u3066\u898b\u3084\u3059\u304f\u8868\u793a\u3059\u308b\u65b9\u6cd5"},"content":{"rendered":"<p>\u5148\u65e5\u3001\u3053\u3093\u306a\u304a\u305f\u3088\u308a\u3092\u9802\u304d\u307e\u3057\u305f\u3002<\/p>\n<blockquote><p>\n\u521d\u3081\u307e\u3057\u3066\u3001RSS\u306b\u767b\u9332\u3057\u3066\u3044\u3064\u3082\u52c9\u5f37\u3055\u305b\u3066\u3082\u3089\u3063\u3066\u307e\u3059\u3002<\/p>\n<p>\u5148\u65e5\u306e\u8a18\u4e8b\u300c<a href=\"https:\/\/stocker.jp\/diary\/bookmark\/\" target=\"_blank\">\u7ba1\u7406\u4eba\u306e\u65b0\u7740\u30d6\u30c3\u30af\u30de\u30fc\u30af\u3092\u898b\u308c\u308b\u30da\u30fc\u30b8\u3092\u4f5c\u308a\u307e\u3057\u305f | Stocker.jp \/ diary<\/a>\u300d\u3092\u898b\u3066\u3068\u3066\u3082\u885d\u6483\u3092\u53d7\u3051\u307e\u3057\u305f\u3002<br \/>\n\u4eca\u307e\u3067\u898b\u305f\u3069\u306e\u500b\u4eba\u30cb\u30e5\u30fc\u30b9\u30b5\u30a4\u30c8\u3088\u308a\u3082\u898b\u3084\u3059\u304f\u30d6\u30c3\u30af\u30de\u30fc\u30af\u304c\u307e\u3068\u307e\u3063\u3066\u3044\u3066<br \/>\n\u306f\u3066\u30d6\u6570\u3084\u3001\u306a\u306b\u3088\u308a\u30b3\u30e1\u30f3\u30c8\u307e\u3067\u5f15\u7528\u3067\u304d\u3066\u3044\u308b\u306e\u306f\u7d20\u6674\u3089\u3057\u3044\u306e\u4e00\u8a00\u3067\u3059\u3002<br \/>\n\u3053\u308c\u3092\u4f5c\u3063\u305f\u904e\u7a0b\u306e\u8a18\u4e8b\u306a\u3093\u304b\u304c\u898b\u305f\u3044\u306a\u30fc\uff08\u30c1\u30e9\u30c3\n<\/p><\/blockquote>\n<p>\u3068\u3044\u3046\u308f\u3051\u3067\u3001PHP \u3067\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u3092\u6574\u5f62\u3057\u3066\u898b\u3084\u3059\u304f\u8868\u793a\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u66f8\u304d\u307e\u3059\u3002<br \/>\n\u5177\u4f53\u7684\u306b\u8a00\u3046\u3068\u3001\u3053\u308c\u2193\u306e\u4f5c\u308a\u65b9\u3067\u3059\u306d\u3002<br \/>\n<a href=\"https:\/\/stocker.jp\/bookmark\/\" target=\"_blank\">Stocker.jp \u7ba1\u7406\u4eba\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af<\/a><\/p>\n<h3><span class=\"ez-toc-section\" id=\"%E6%A6%82%E8%A6%81\"><\/span>\u6982\u8981<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>\u5177\u4f53\u7684\u306b\u8a00\u3046\u3068\u3001\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306f\u30e6\u30fc\u30b6\u30fc\u3054\u3068\u306b <a href=\"http:\/\/ja.wikipedia.org\/wiki\/RSS\" target=\"_blank\">RSS<\/a> \u304c\u767a\u884c\u3055\u308c\u3066\u3044\u307e\u3059\u306e\u3067\u3001PHP \u3067\u305d\u308c\u3092\u8aad\u307f\u8fbc\u3093\u3067 simplexml_load_file() \u3068\u3044\u3046\u95a2\u6570\u3067 <a href=\"http:\/\/e-words.jp\/w\/E38391E383BCE382B9.html\" target=\"_blank\">RSS\u3092\u30d1\u30fc\u30b9\uff08\u89e3\u6790\uff09<\/a> \u3057\u3066\u8868\u793a\u3057\u3066\u3044\u308b\u3060\u3051\u3067\u3059\u3002<br \/>\nMySQL \u7b49\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3059\u3089\u4f7f\u3063\u3066\u3044\u306a\u3044\u3001\u8d85\u30b7\u30f3\u30d7\u30eb\u3067\u7c21\u5358\u306a\u30b9\u30af\u30ea\u30d7\u30c8\u3067\u3059\u3002<\/p>\n<p>\u5b9f\u306f\u3001\u3053\u306ePHP\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u66f8\u3044\u305f\u6642\u3001\u3061\u3087\u3046\u3069 <a href=\"http:\/\/cakephp.jp\/\" target=\"_blank\">CakePHP<\/a> \u3068\u3044\u3046\u6709\u540d\u306aPHP\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306e\u52c9\u5f37\u4e2d\u3060\u3063\u305f\u306e\u3067\u3001\u300cCakePHP \u3067\u4f5c\u308b\u306e\u306b\u306f\u5411\u3044\u3066\u3044\u306a\u3044\u300d\u3068\u5206\u304b\u3063\u3066\u3044\u306a\u304c\u3089\u3082\u8a66\u3057\u306b CakePHP \u3067\u4f5c\u3063\u3066\u307f\u307e\u3057\u305f\u3002<\/p>\n<p>CakePHP \u306e\u3088\u3046\u306a <a href=\"http:\/\/www.objective-php.net\/mvc\/about\" target=\"_blank\">MVC\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af<\/a> \u3092\u4f7f\u3046\u306e\u306f\u521d\u3081\u3066\u3060\u3063\u305f\u306e\u3067\u3001\u304b\u306a\u308a\u56db\u82e6\u516b\u82e6\u3057\u306a\u304c\u3089\u3082\u306a\u3093\u3068\u304b\u4f5c\u308b\u3053\u3068\u304c\u3067\u304d\u305f\u306e\u3067\u3059\u304c\u3001\u79c1\u304c\u4f7f\u7528\u3057\u3066\u3044\u308b <a href=\"http:\/\/px.a8.net\/svt\/ejp?a8mat=1TSWXG+CONHRM+D8Y+BWVTE\" target=\"_blank\">\u3055\u304f\u3089\u306eVPS 512<\/a> \u3067\u306f\u30e1\u30e2\u30ea\u4e0d\u8db3\u306e\u8b66\u544a\u304c\u3067\u3066\u3057\u307e\u3044\u307e\u3057\u305f\u3002<\/p>\n<p>\u4ed5\u65b9\u306a\u3044\u306e\u3067\u3001CakePHP \u3067\u4f5c\u3063\u305f\u3082\u306e\u3092\u4e00\u65e6\u666e\u901a\u306e PHP \u3067\u66f8\u304d\u306a\u304a\u3057\u305f\u305f\u3081\u3001\u69cb\u9020\u304c MVC \u3063\u307d\u304f\uff08\uff1f\uff093\u3064\u306e\u30d5\u30a1\u30a4\u30eb\u306b\u5206\u304b\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<h3><span class=\"ez-toc-section\" id=\"%E3%81%AF%E3%81%A6%E3%81%AA%E3%83%96%E3%83%83%E3%82%AF%E3%83%9E%E3%83%BC%E3%82%AF%E3%81%AERSS%E3%81%AE%E4%BB%95%E6%A7%98\"><\/span>\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306eRSS\u306e\u4ed5\u69d8<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306e\u81ea\u5206\u306e RSS \u3092\u898b\u308b\u306b\u306f\u3001<br \/>\nhttp:\/\/b.hatena.ne.jp\/\u306f\u3066\u306aID\/rss<br \/>\n\u3068\u3044\u3046 URL \u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\u3060\u3051\u3067\u3059\u3002<\/p>\n<p>\u2026\u304c\u3001\u3053\u306e RSS\u3001\u5b9f\u306f1\u5ea6\u306b20\u4ef6\u305a\u3064\u3057\u304b\u8868\u793a\u3055\u308c\u307e\u305b\u3093\u3002<br \/>\n2\u30da\u30fc\u30b8\u76ee\u4ee5\u964d\u3092\u8868\u793a\u3057\u305f\u3051\u308c\u3070\u3001URL\u306e\u6700\u5f8c\u306b of=20 \u306e\u3088\u3046\u306a\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u8ffd\u52a0\u3057\u3066<\/p>\n<p>2\u30da\u30fc\u30b8\u76ee\u3092\u8868\u793a\u3059\u308bURL<br \/>\nhttp:\/\/b.hatena.ne.jp\/\u306f\u3066\u306aID\/rss?of=20<br \/>\n3\u30da\u30fc\u30b8\u76ee\u3092\u8868\u793a\u3059\u308bURL<br \/>\nhttp:\/\/b.hatena.ne.jp\/\u306f\u3066\u306aID\/rss?of=40<\/p>\n<p>\u306e\u3088\u3046\u306b\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f\u3001URL\u306b of \u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u3064\u3051\u308b\u3068\u6b21\u306e\u30da\u30fc\u30b8\u3092\u8aad\u307f\u8fbc\u3081\u308b\u3088\u3046\u306b\u3057\u307e\u3057\u305f\u3002<br \/>\n\u3064\u307e\u308a\u3001\u6700\u65b020\u4ef6\u3092\u8868\u793a\u3059\u308b\u5834\u5408\u306eURL<br \/>\nhttps:\/\/stocker.jp\/bookmark\/<br \/>\n\u6b21\u306e20\u4ef6\u3092\u8868\u793a\u3059\u308bURL<br \/>\nhttps:\/\/stocker.jp\/bookmark\/?of=20<br \/>\n\u3068\u3044\u3046\u611f\u3058\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<h3><span class=\"ez-toc-section\" id=\"%E4%BD%9C%E3%82%8A%E6%96%B9\"><\/span>\u4f5c\u308a\u65b9<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>\u79c1\u306f PHP \u3092\u66f8\u304d\u59cb\u3081\u305f\u3070\u304b\u308a\u306e\u9803\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u30bd\u30fc\u30b9\u3092\u66f8\u3044\u3066\u3044\u307e\u3057\u305f\u3002<\/p>\n<pre lang=\"php\" line=\"1\">\r\n<?php\r\n\/* \u3053\u3053\u306b\u51e6\u7406\u3092\u66f8\u304f *\/\r\n?>\r\n<!-- \u3053\u3053\u306bHTML\u3092\u66f8\u304f -->\r\n<\/pre>\n<p>\u3057\u304b\u3057\u3001\u30bd\u30fc\u30b9\u306e\u91cf\u304c\u5897\u3048\u3066\u304d\u305f\u308a\u95a2\u6570\u3092\u3088\u304f\u4f7f\u3046\u3088\u3046\u306b\u306a\u308b\u3068\u3053\u306e\u65b9\u6cd5\u3067\u306f\u898b\u3065\u3089\u304f\u611f\u3058\u3066\u3001\u95a2\u6570\u3060\u3051\u5225\u30d5\u30a1\u30a4\u30eb\u306b\u5206\u3051\u305f\u308a\u3057\u3066\u3044\u307e\u3057\u305f\u3002<\/p>\n<p>\u4eca\u56de\u306f\u4e00\u5ea6 CakePHP \u3067\u4f5c\u3063\u3066\u3044\u305f\u3053\u3068\u3082\u3042\u308a\u3001<\/p>\n<ul>\n<li>\u4ed6\u306e\u30d5\u30a1\u30a4\u30eb\u3092\u30a4\u30f3\u30af\u30eb\u30fc\u30c9\u3059\u308b\u305f\u3081\u306e\u30d5\u30a1\u30a4\u30eb\uff08index.php\uff09<\/li>\n<li>\u95a2\u6570\u3092\u307e\u3068\u3081\u305f\u30d5\u30a1\u30a4\u30eb\uff08functions.php\uff09<\/li>\n<li>\u30c6\u30fc\u30de\u30d5\u30a1\u30a4\u30eb\uff08theme.php\uff09<\/li>\n<\/ul>\n<p>\u306e3\u3064\u306e\u30d5\u30a1\u30a4\u30eb\u306b\u5206\u3051\u3066\u4f5c\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<h4>\u4ed6\u306e\u30d5\u30a1\u30a4\u30eb\u3092\u30a4\u30f3\u30af\u30eb\u30fc\u30c9\u3059\u308b\u305f\u3081\u306e\u30d5\u30a1\u30a4\u30eb\uff08index.php\uff09<\/h4>\n<pre lang=\"php\" line=\"1\">\r\n<?php\r\n\/* \u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306e\u8868\u793a *\/\r\n\r\n\/\/ WordPress\u306e\u8aad\u307f\u8fbc\u307f\uff08\u3053\u308c\u3067WP\u95a2\u6570\u4f7f\u3048\u308b\u3088\u3046\u306b\u306a\u308b\uff09\r\ninclude ('..\/diary\/wp-load.php');\r\n\r\n\/\/ \u95a2\u6570\u30d5\u30a1\u30a4\u30eb\u306e\u8aad\u307f\u8fbc\u307f\r\ninclude ('functions.php');\r\n\r\n\/\/ HTML\u306e\u8aad\u307f\u8fbc\u307f\r\ninclude ('theme.php');\r\n<\/pre>\n<p>5\u884c\u76ee\u3067\u3069\u3046\u3057\u3066WordPress\u3092\u8aad\u307f\u8fbc\u3093\u3067\u3044\u308b\u304b\u3068\u3044\u3046\u3068\u3001\u30b5\u30a4\u30c9\u30d0\u30fc\u306b\u30d6\u30ed\u30b0\u3068\u5171\u901a\u306e\u30b5\u30a4\u30c9\u30d0\u30fc\u3092\u8868\u793a\u3057\u305f\u3044\u304b\u3089\u3067\u3059\u3002<br \/>\nWordPress\u30d5\u30a9\u30eb\u30c0\u5185\u306b\u3042\u308b wp-load.php \u3092 include \u3059\u308b\u3068\u3001WordPress \u306e\u72ec\u81ea\u95a2\u6570\u304c\u4f7f\u3048\u308b\u3088\u3046\u306b\u306a\u308b\u306e\u3067\u3001\u305d\u308c\u3092\u4f7f\u3063\u3066\u30d6\u30ed\u30b0\u3068\u5171\u901a\u306e\u30b5\u30a4\u30c9\u30d0\u30fc\u3092\u8868\u793a\u3055\u305b\u307e\u3059\u3002<\/p>\n<h4>\u95a2\u6570\u3092\u307e\u3068\u3081\u305f\u30d5\u30a1\u30a4\u30eb\uff08functions.php\uff09<\/h4>\n<pre lang=\"php\" line=\"1\">\r\n<?php\r\n\r\nfunction rss2html() {\r\n\r\n\t\/\/ of \u306f\u4f55\u4ef6\u76ee\u304b\u3089\u53d6\u5f97\u3059\u308b\u304b\r\n\t$of = isset($_GET['of']) ? $_GET['of'] : 0;\r\n\r\n\tif (! is_numeric($of)) {\r\n\t\t$of = 0;\r\n\t}\r\n\r\n\t\/\/ RSS\u306e\u8aad\u307f\u8fbc\u307f\r\n\t$xml = simplexml_load_file('http:\/\/b.hatena.ne.jp\/hatena_id\/rss?of=' . $of);\t\/\/ of=20 \u3067\u6b21\u30da\u30fc\u30b8\r\n\r\n\t\/\/ $output \u306b null \u3092\u4ee3\u5165\uff08Notice\u9632\u6b62\uff09\r\n\t$output = null;\r\n\r\n\tforeach ($xml->item as $item) {\r\n\t\t$dc = $item->children('http:\/\/purl.org\/dc\/elements\/1.1\/');\r\n\t\t$date = date('n\u6708j\u65e5', strtotime($dc->date));\r\n\t\tif ($date !== $date_log){\r\n\t\t\t$output .= '<h3><span class=\"ez-toc-section\" id=\"_date_%E3%81%AE%E3%83%96%E3%83%83%E3%82%AF%E3%83%9E%E3%83%BC%E3%82%AF\"><\/span>' . $date . '\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af<span class=\"ez-toc-section-end\"><\/span><\/h3>';\r\n\t\t\t$date_log = $date;\r\n\t\t}\r\n\t\t$output .= '<article><a class=\"bm_cap_a\" href=\"' . $item->link . '\" target=\"_blank\"><div class=\"bm_cap\" style=\"background:url(http:\/\/s.wordpress.com\/mshots\/v1\/' . urlencode($item->link) . '?w=200);\"><\/div><\/a>';\r\n\t\t$output .= '<h4 class=\"bm_content_h4\"><a href=\"' . $item->link . '\" target=\"_blank\">' . $item->title . '<\/a><\/h4><img decoding=\"async\" class=\"bm_count\" src=\"http:\/\/b.hatena.ne.jp\/entry\/image\/' . $item->link . '\"><br \/>' . PHP_EOL;\r\n\t\t$output .= '<p>' . $item->description . '<\/p><\/article>' . PHP_EOL;\r\n\t}\r\n\r\n\treturn $output;\r\n}\r\n\r\nfunction bm_next() {\r\n\r\n\t\/\/ of \u306f\u4f55\u4ef6\u76ee\u304b\u3089\u53d6\u5f97\u3059\u308b\u304b\r\n\t$of = isset($_GET['of']) ? $_GET['of'] : 0;\r\n\r\n\tif (is_numeric($of)) {\r\n\r\n\t\t\/\/ of \u306b20\u3092\u8db3\u3059\r\n\t\t$of = $of + 20;\r\n\r\n\t\t$output = '\t\t\t\t\t\t<div id=\"bm_next\">\r\n\t\t\t\t\t\t<a href=\"https:\/\/stocker.jp\/bookmark\/?of=' . $of . '\">\u6b21\u306e20\u4ef6<\/a>\r\n\t\t\t\t\t<\/div>';\r\n\r\n\t} else if (! $of) {\r\n\r\n\t\t$output = '\t\t\t\t\t\t<div id=\"bm_next\">\r\n\t\t\t\t\t\t<a href=\"https:\/\/stocker.jp\/bookmark\/?of=20\">\u6b21\u306e20\u4ef6<\/a>\r\n\t\t\t\t\t<\/div>';\t\t\t\r\n\t}\r\n\r\n\treturn $output;\r\n\r\n}\r\n\r\nfunction bm_prev() {\r\n\r\n\t\/\/ $output \u521d\u671f\u5316\r\n\t$output = null;\r\n\r\n\t\/\/ of \u306f\u4f55\u4ef6\u76ee\u304b\u3089\u53d6\u5f97\u3059\u308b\u304b\r\n\t$of = isset($_GET['of']) ? $_GET['of'] : 0;\r\n\r\n\tif (is_numeric($of) and $of >= 20) {\r\n\r\n\t\t\/\/ of \u304b\u308920\u3092\u5f15\u304f\r\n\t\t$of = $of - 20;\r\n\r\n\t\tif ($of <= 0) {\r\n\r\n\t\t\t$output = '\t<div id=\"bm_prev\">\r\n\t\t\t\t\t\t<a href=\"https:\/\/stocker.jp\/bookmark\/\">\u524d\u306e20\u4ef6<\/a>\r\n\t\t\t\t\t<\/div>';\r\n\r\n\t\t} else {\r\n\r\n\t\t\t$output = '\t<div id=\"bm_prev\">\r\n\t\t\t\t\t\t<a href=\"https:\/\/stocker.jp\/bookmark\/?of=' . $of . '\">\u524d\u306e20\u4ef6<\/a>\r\n\t\t\t\t\t<\/div>';\r\n\r\n\t\t}\r\n\r\n\t}\r\n\r\n\treturn $output;\r\n\r\n}\r\n<\/pre>\n<p>functions.php \u306f<\/p>\n<ul>\n<li>RSS \u3092\u8aad\u307f\u8fbc\u3093\u3067 HTML \u3092\u8868\u793a\u3059\u308b\u305f\u3081\u306e rss2html() \u95a2\u6570<\/li>\n<li>\u300c\u6b21\u306e20\u4ef6\u300d\u3092\u8868\u793a\u3059\u308b\u305f\u3081\u306e bm_next() \u95a2\u6570<\/li>\n<li>\u300c\u524d\u306e20\u4ef6\u300d\u3092\u8868\u793a\u3059\u308b\u305f\u3081\u306e bm_prev() \u95a2\u6570<\/li>\n<\/ul>\n<p>\u306e3\u3064\u306e\u95a2\u6570\u304c\u66f8\u304b\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre lang=\"php\" line=\"5\">\r\n\t\/\/ of \u306f\u4f55\u4ef6\u76ee\u304b\u3089\u53d6\u5f97\u3059\u308b\u304b\r\n\t$of = isset($_GET['of']) ? $_GET['of'] : 0;\r\n<\/pre>\n<p>6\u884c\u76ee\u306f <a href=\"http:\/\/www.phpbook.jp\/tutorial\/if\/index8.html\" target=\"_blank\">\u4e09\u9805\u6f14\u7b97\u5b50<\/a> \u3067 'of' \u3068\u3044\u3046\u30d1\u30e9\u30e1\u30fc\u30bf\u304c\u30bb\u30c3\u30c8\u3055\u308c\u3066\u3044\u308c\u3070\u305d\u308c\u3092\u5909\u6570 $of \u306b\u4ee3\u5165\u3057\u3001\u30bb\u30c3\u30c8\u3055\u308c\u3066\u3044\u306a\u3051\u308c\u3070 0 \u3092\u5909\u6570 $of \u306b\u4ee3\u5165\u3055\u308c\u308b\u3088\u3046\u306b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre lang=\"php\" line=\"8\">\r\n\tif (! is_numeric($of)) {\r\n\t\t$of = 0;\r\n\t}\r\n<\/pre>\n<p>8\u301c10\u884c\u76ee\u306f\u3044\u305f\u305a\u3089\u9632\u6b62\u3067\u3001\u3082\u3057 'of' \u3068\u3044\u3046\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u5024\u304c\u6570\u5b57\u3067\u306a\u3051\u308c\u3070 0 \u3092\u4ee3\u5165\u3057\u3066\u3057\u307e\u3046\u3088\u3046\u306b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre lang=\"php\" line=\"12\">\r\n\t\/\/ RSS\u306e\u8aad\u307f\u8fbc\u307f\r\n\t$xml = simplexml_load_file('http:\/\/b.hatena.ne.jp\/hatena_id\/rss?of=' . $of);\t\/\/ of=20 \u3067\u6b21\u30da\u30fc\u30b8\r\n<\/pre>\n<p>13\u884c\u76ee\u306f\u3001 hatena_id \u90e8\u5206\u306b\u81ea\u5206\u306e\u306f\u3066\u306aID\u3092\u5165\u308c\u307e\u3059\u3002<br \/>\nsimplexml_load_file() \u95a2\u6570\u3092\u4f7f\u3046\u3068\u3001<a href=\"http:\/\/www.webcreatornote.com\/2011\/04\/%E8%87%AA%E4%BD%9Crss%E3%83%AA%E3%83%BC%E3%83%80%E3%82%82%E7%B0%A1%E5%8D%98%E3%81%AB%E4%BD%9C%E3%82%8C%E3%82%8B%E3%80%81simplexml_load_file%E3%81%8C%E4%BE%BF%E5%88%A9%E3%81%99%E3%81%8E%E3%82%8B\/\" target=\"_blank\">\u7c21\u5358\u306b XML \u3092\u30d1\u30fc\u30b9\u3057\u3066 RSS \u30ea\u30fc\u30c0\u30fc\u306e\u3088\u3046\u306a\u3082\u306e\u3092\u4f5c\u308c\u308b<\/a> \u306e\u3067\u304b\u306a\u308a\u4fbf\u5229\u3067\u3059\u3002<\/p>\n<p>\u305f\u3060\u3001\u7d30\u304b\u3044\u60c5\u5831\u304c\u53d6\u5f97\u3067\u304d\u306a\u304b\u3063\u305f\u308a\u3059\u308b\u306e\u3067\u3059\u304c\u3053\u308c\u306b\u3064\u3044\u3066\u306f\u5f8c\u8ff0\u3057\u307e\u3059\u3002<br \/>\n\u30d1\u30fc\u30b9\u3057\u305f XML \u3092\u3001\u5909\u6570 $xml \u306b\u4ee3\u5165\u3057\u307e\u3059\u3002<\/p>\n<pre lang=\"php\" line=\"15\">\r\n\t\/\/ $output \u306b null \u3092\u4ee3\u5165\uff08Notice\u9632\u6b62\uff09\r\n\t$output = null;\r\n<\/pre>\n<p>16\u884c\u76ee\u306f\u3001\u5909\u6570 $output \u306b\u4f55\u3082\u4ee3\u5165\u3055\u308c\u3066\u3044\u306a\u3044\u3068 PHP \u306e Notice \u304c\u51fa\u3066\u3057\u307e\u3046\u306e\u3067\u3001null \u3092\u4ee3\u5165\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre lang=\"php\" line=\"18\">\r\n\tforeach ($xml->item as $item) {\r\n\t\t$dc = $item->children('http:\/\/purl.org\/dc\/elements\/1.1\/');\r\n\t\t$date = date('n\u6708j\u65e5', strtotime($dc->date));\r\n\t\tif ($date !== $date_log){\r\n\t\t\t$output .= '<h3><span class=\"ez-toc-section\" id=\"_date_%E3%81%AE%E3%83%96%E3%83%83%E3%82%AF%E3%83%9E%E3%83%BC%E3%82%AF-2\"><\/span>' . $date . '\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af<span class=\"ez-toc-section-end\"><\/span><\/h3>';\r\n\t\t\t$date_log = $date;\r\n\t\t}\r\n\t\t$output .= '<article><a class=\"bm_cap_a\" href=\"' . $item->link . '\" target=\"_blank\"><div class=\"bm_cap\" style=\"background:url(http:\/\/s.wordpress.com\/mshots\/v1\/' . urlencode($item->link) . '?w=200);\"><\/div><\/a>';\r\n\t\t$output .= '<h4 class=\"bm_content_h4\"><a href=\"' . $item->link . '\" target=\"_blank\">' . $item->title . '<\/a><\/h4><img decoding=\"async\" class=\"bm_count\" src=\"http:\/\/b.hatena.ne.jp\/entry\/image\/' . $item->link . '\"><br \/>' . PHP_EOL;\r\n\t\t$output .= '<p>' . $item->description . '<\/p><\/article>' . PHP_EOL;\r\n\t}\r\n<\/pre>\n<p>18\u301c28\u884c\u76ee\u306f\u3001foreach \u3092\u4f7f\u3063\u3066\u5909\u6570 $xml \u306e\u5185\u5bb9\u3092\u30d0\u30e9\u3057\u3066\u3001\u51fa\u529b\u7528\u306e HTML \u3092\u5909\u6570 $output \u306b\u4ee3\u5165\u3057\u3066\u3044\u307e\u3059\u3002<br \/>\n\u81ea\u5206\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af\u30b3\u30e1\u30f3\u30c8\u3092\u8868\u793a\u3055\u305b\u308b\u306b\u306f $item->description \u3092\u5165\u308c\u308b\u3060\u3051\u3067\u3059\u3002<\/p>\n<p>19\u301c20\u884c\u76ee\u306f\u3001RSS \u306b\u542b\u307e\u308c\u308b\u65e5\u4ed8\u306e\u90e8\u5206\u3092\u89e3\u6790\u3057\u3066\u3044\u307e\u3059\u3002<br \/>\n\u65e5\u4ed8\u306e\u90e8\u5206\u3092\u89e3\u6790\u3059\u308b\u306b\u306f children \u30e1\u30bd\u30c3\u30c9\u306e\u5f15\u6570\u306b\u540d\u524d\u7a7a\u9593\u3092\u6307\u5b9a\u3059\u308b\u5fc5\u8981\u304c\u3042\u308b\u305d\u3046\u3067\u3001\u3053\u3061\u3089\u306e\u30da\u30fc\u30b8\u3092\u53c2\u8003\u306b\u3055\u305b\u3066\u9802\u304d\u307e\u3057\u305f\u3002<br \/>\n<a href=\"http:\/\/blog.diginnovation.com\/archives\/203\/\" target=\"_blank\">PHP\u306eSimpleXML\u95a2\u6570\u3067RSS1.0\u306e\u300cdc:date\u300d\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5 | \u81ea\u7531\u304c\u4e18\u3067\u50cd\u304fWeb\u5c4b\u306e\u30d6\u30ed\u30b0<\/a><\/p>\n<p>21\u301c23\u884c\u76ee\u3067\u3001\u65e5\u4ed8\u304c\u7570\u306a\u308c\u3070\u65e5\u4ed8\u3092\u898b\u51fa\u3057\u3068\u3057\u3066\u8ffd\u52a0\u3057\u3001\u65e5\u4ed8\u304c\u540c\u3058\u3067\u3042\u308c\u3070\u4f55\u3082\u3057\u306a\u3044\u3088\u3046\u306b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre lang=\"php\" line=\"30\">\r\n\treturn $output;\r\n<\/pre>\n<p>30\u884c\u76ee\u3067\u5909\u6570 $output \u3092 return \u3057\u307e\u3059\u3002<\/p>\n<p>\u6b21\u306f bm_next() \u95a2\u6570\u3067\u3059\u3002<br \/>\n'of' \u3068\u3044\u3046\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u5024\u304c\u6570\u5b57\u3067\u3042\u308c\u3070\u3001\u6b21\u30da\u30fc\u30b8\u3078\u306e\u30ea\u30f3\u30af\uff08\u73fe\u5728\u306e 'of' \u3068\u3044\u3046\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u5024+20\uff09\u3092\u8868\u793a\u3057\u3001\u6570\u5b57\u3067\u306a\u3051\u308c\u3070\uff08\u901a\u5e38\u306f\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u5024\u304c\u5b58\u5728\u3057\u306a\u3051\u308c\u3070\uff092\u30da\u30fc\u30b8\u76ee\u306e\u30ea\u30f3\u30af\u3068\u3057\u3066 \/bookmark\/?of=20 \u3092\u8868\u793a\u3059\u308b\u3060\u3051\u3067\u3059\u3002<\/p>\n<p>\u6700\u5f8c\u306f bm_prev() \u95a2\u6570\u3067\u3059\u3002<br \/>\n'of' \u3068\u3044\u3046\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u5024\u304c\u6570\u5b57\u3067\u3001\u304b\u306420\u4ee5\u4e0a\u3067\u3042\u308c\u3070\u300120\u3092\u5f15\u3044\u3066\u307f\u30660\u306b\u306a\u3063\u305f\u3089 'of' \u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u306a\u3044\u30ea\u30f3\u30af\uff08\/bookmark\/\uff09\u3092\u8868\u793a\u3057\u3001\u305d\u3046\u3067\u306a\u3051\u308c\u3070\u524d\u30da\u30fc\u30b8\u3078\u306e\u30ea\u30f3\u30af\uff08\u73fe\u5728\u306e 'of' \u3068\u3044\u3046\u30d1\u30e9\u30e1\u30fc\u30bf\u306e\u5024-20\uff09\u3092\u8868\u793a\u3057\u307e\u3059\u3002<\/p>\n<h4>\u30c6\u30fc\u30de\u30d5\u30a1\u30a4\u30eb\uff08theme.php\uff09<\/h4>\n<pre lang=\"php\" line=\"1\">\r\n<!DOCTYPE HTML>\r\n<html lang=\"ja\">\r\n<head>\r\n\t<meta charset=\"UTF-8\">\r\n\t<title>\u7ba1\u7406\u4eba\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af<\/title>\r\n\t<link rel=\"stylesheet\" type=\"text\/css\" href=\"style.css\" \/>\r\n<\/head>\r\n<body>\r\n\t<h1>\u7ba1\u7406\u4eba\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af<\/h1>\r\n\t<div id=\"main\">\r\n\t\t<div class=\"bm_content\">\r\n\t\t\t<?php echo rss2html(); ?>\r\n\t\t\t<?php echo bm_next(); ?>\r\n\t\t\t<?php echo bm_prev(); ?>\r\n\t\t<\/div>\r\n\t<\/div>\r\n\t<?php get_sidebar(); ?>\r\n<\/body>\r\n<\/html>\r\n<\/pre>\n<p>\u5b9f\u969b\u306f\u3082\u3063\u3068\u8272\u3005\u66f8\u304b\u308c\u3066\u3044\u308b\u306e\u3067\u3059\u304c\u3001\u3053\u3053\u3067\u306f\u8aac\u660e\u306e\u305f\u3081\u30b7\u30f3\u30d7\u30eb\u306b\u3057\u3066\u3044\u307e\u3059\u3002<br \/>\n\u30c6\u30fc\u30de\u30d5\u30a1\u30a4\u30eb\u3067\u306f\u3001\u5148\u307b\u3069\u306e3\u3064\u306e\u95a2\u6570\u304b\u3089 return \u3055\u308c\u305f\u3082\u306e\u3092\u8868\u793a\u3057\u3001\u3064\u3044\u3067\u306b WordPress \u306e get_sidebar() \u95a2\u6570\u3067 WordPress \u306e\u30b5\u30a4\u30c9\u30d0\u30fc\u3092\u8868\u793a\u3055\u305b\u3066\u3044\u307e\u3059\u3002<br \/>\n\uff08index.php \u3067 WordPress \u3092\u8aad\u307f\u8fbc\u3093\u3067\u3044\u308b\u305f\u3081\u3001WordPress \u306e\u95a2\u6570\u304c\u4f7f\u3048\u307e\u3059\uff09<\/p>\n<p>\u95a2\u6570\u3092\u5225\u30d5\u30a1\u30a4\u30eb\u306b\u5206\u3051\u3066\u304a\u304f\u3068\u3001\u30c6\u30fc\u30de\u30d5\u30a1\u30a4\u30eb\u304c\u3059\u3063\u304d\u308a\u898b\u3084\u3059\u304f\u3066\u826f\u3044\u3067\u3059\u306d\u3002<\/p>\n<h3><span class=\"ez-toc-section\" id=\"%E8%A6%8B%E3%82%84%E3%81%99%E3%81%95%E3%81%AE%E3%81%9F%E3%82%81%E3%81%AE%E5%B7%A5%E5%A4%AB\"><\/span>\u898b\u3084\u3059\u3055\u306e\u305f\u3081\u306e\u5de5\u592b<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>\u308f\u3056\u308f\u3056\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u3092\u8aad\u307f\u8fbc\u3093\u3067\u8868\u793a\u3059\u308b\u30da\u30fc\u30b8\u3092\u4f5c\u308b\u306a\u3089\u3001\u30da\u30fc\u30b8\u306e\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8\u306f\u7d76\u5bfe\u306b\u4ed8\u3051\u305f\u3044\u3068\u601d\u3063\u3066\u3044\u307e\u3057\u305f\u3002<br \/>\n\u79c1\u306f\u4ee5\u524d\u3001\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u3067\u306f\u306a\u304f <a href=\"http:\/\/clip.livedoor.com\/\" target=\"_blank\">livedoor \u30af\u30ea\u30c3\u30d7<\/a> \u3068\u3044\u3046\u30bd\u30fc\u30b7\u30e3\u30eb\u30d6\u30c3\u30af\u30de\u30fc\u30af\u30b5\u30fc\u30d3\u30b9\u3092\u5229\u7528\u3057\u3066\u3044\u307e\u3057\u305f\u3002<br \/>\n\u306a\u305c\u304b\u3068\u3044\u3046\u3068\u3001\u5404\u30da\u30fc\u30b8\u3054\u3068\u306b\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8\u304c\u8868\u793a\u3055\u308c\u3066\u3044\u3066\u898b\u3084\u3059\u3044\u3068\u601d\u3063\u305f\u304b\u3089\u3067\u3059\u3002<\/p>\n<p>\u305f\u3060\u3001\u3068\u3042\u308b\u4f1a\u793e\u3067\u50cd\u3044\u305f\u6642\u306b livedoor \u3078\u306e\u30ed\u30b0\u30a4\u30f3\u304c\u7981\u6b62\u3055\u308c\u3066\u5229\u7528\u3067\u304d\u306a\u304f\u306a\u3063\u305f\u306e\u3067\u3001\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u3078\u79fb\u884c\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8\u306f <a href=\"http:\/\/developer.cybozu.co.jp\/akky\/2010\/07\/wordpresscomapi.html\" target=\"_blank\">WordPress.com \u306e API<\/a> \u3092\u5229\u7528\u3057\u3001\u96a3\u306b\u8868\u793a\u3059\u308b\u30bf\u30a4\u30c8\u30eb\u304c1\u301c2\u884c\u3001\u30b3\u30e1\u30f3\u30c8\u304c1\u301c2\u884c\u3068\u3044\u3046\u3053\u3068\u3092\u8003\u3048\u308b\u3068 width: 120px; height: 75px; \u304c\u826f\u3044\u304b\u306a\u3068\u601d\u3044\u307e\u3057\u305f\u3002<\/p>\n<p>\u305f\u3060\u3001\u666e\u901a\u306b 120x75 \u3067\u8868\u793a\u3057\u3066\u307f\u308b\u3068\u3001\u30b5\u30a4\u30c8\u306e\u30ed\u30b4\u304c\u307b\u3068\u3093\u3069\u5224\u5225\u3067\u304d\u306a\u3044\u30ec\u30d9\u30eb\u3067\u898b\u3065\u3089\u3044\u306a\u3068\u611f\u3058\u307e\u3057\u305f\u3002<br \/>\n\u3082\u3061\u308d\u3093\u3001\u8868\u793a\u30b5\u30a4\u30ba\u3092\u5927\u304d\u304f\u3059\u308c\u3070\u898b\u3084\u3059\u304f\u306f\u306a\u308a\u307e\u3059\u304c\u3001\u3069\u3046\u3057\u3066\u3082\u30b9\u30ab\u30b9\u30ab\u306a\u5370\u8c61\u306b\u306a\u3063\u3066\u3057\u307e\u3044\u307e\u3059\u3002<\/p>\n<p>\u305d\u3053\u3067\u3001\u67a0\u306f 120x75 \u306e\u307e\u307e\u3001\u4e2d\u8eab\u3060\u3051\u62e1\u5927\u3059\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<br \/>\n\u5927\u62b5\u306e\u30b5\u30a4\u30c8\u306f\u5de6\u4e0a\u306b\u30ed\u30b4\u304c\u3042\u308b\u306e\u3067\u3001\u3053\u308c\u3067\u3060\u3044\u3076\u898b\u3084\u3059\u304f\u306a\u3063\u305f\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" src=\"https:\/\/i0.wp.com\/stocker.jp\/diary\/wp-content\/uploads\/bm10.png?resize=500%2C300&#038;ssl=1\" alt=\"\u4e2d\u8eab\u3092\u62e1\u5927\u3057\u3066\u8868\u793a\" title=\"\" width=\"500\" height=\"300\" class=\"alignnone size-full wp-image-1796\" srcset=\"https:\/\/i0.wp.com\/stocker.jp\/diary\/wp-content\/uploads\/bm10.png?w=500&amp;ssl=1 500w, https:\/\/i0.wp.com\/stocker.jp\/diary\/wp-content\/uploads\/bm10.png?resize=300%2C180&amp;ssl=1 300w\" sizes=\"auto, (max-width: 500px) 100vw, 500px\" \/><\/p>\n<h3><span class=\"ez-toc-section\" id=\"%E6%B3%A8%E6%84%8F%E7%82%B9\"><\/span>\u6ce8\u610f\u70b9<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>\u30e6\u30fc\u30b6\u30fc\uff08\u95b2\u89a7\u8005\uff09\u304c\u30da\u30fc\u30b8\u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\u305f\u3073\u306b\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306eRSS\u3092\u8aad\u307f\u306b\u884c\u3063\u3066\u3044\u305f\u306e\u3067\u306f\u30da\u30fc\u30b8\u306e\u8868\u793a\u306b\u6642\u9593\u304c\u304b\u304b\u3063\u3066\u3057\u307e\u3044\u307e\u3059\u3057\u3001\u306f\u3066\u306a\u306e\u30b5\u30fc\u30d0\u30fc\u306b\u3082\u4f59\u8a08\u306a\u8ca0\u8377\u3092\u304b\u3051\u3066\u3057\u307e\u3044\u307e\u3059\u3002<\/p>\n<p>\u305d\u3053\u3067\u3001\u79c1\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af\u4e00\u89a7\u30da\u30fc\u30b8\u3067\u306f2\u6642\u9593\u306b1\u5ea6\u3060\u3051\u6700\u65b0\u306e RSS \u3092\u53d6\u5f97\u3057\u3001\u305d\u308c\u3092\u30ad\u30e3\u30c3\u30b7\u30e5\u3059\u308b\u3088\u3046\u306b\u306a\u3063\u3066\u3044\u308b\u306e\u3067\u3059\u304c\u3001PHP \u3067\u306f\u305d\u3046\u3044\u3046\u30b3\u30fc\u30c9\u306f\u66f8\u3044\u3066\u3044\u307e\u305b\u3093\u3002<br \/>\n\u306a\u305c\u304b\u3068\u3044\u3046\u3068\u3001\u79c1\u306e\u30b5\u30fc\u30d0\u306f Apache \u306e\u4ee3\u308f\u308a\u306b Nginx \u3092\u5229\u7528\u3057\u3001PHP \u306e\u51fa\u529b\u7d50\u679c\u30922\u6642\u9593\u30ad\u30e3\u30c3\u30b7\u30e5\u3059\u308b\u3088\u3046\u306b\u306a\u3063\u3066\u3044\u308b\u304b\u3089\u3067\u3059\u3002<\/p>\n<p>\u3067\u3059\u306e\u3067\u3001\u4e00\u822c\u306e\u30ec\u30f3\u30bf\u30eb\u30b5\u30fc\u30d0\u7b49\u3067\u3053\u3046\u3044\u3046\u30da\u30fc\u30b8\u3092\u4f5c\u3089\u308c\u308b\u306e\u3067\u3042\u308c\u3070\u3001\u51fa\u529b\u7d50\u679c\u3092\u305d\u306e\u307e\u307e\u8868\u793a\u3059\u308b\u306e\u3067\u306f\u306a\u304f\u4e00\u65e6\u30d5\u30a1\u30a4\u30eb\u3084 MySQL \u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u7b49\u306b\u4fdd\u5b58\u3057\u30012\u6642\u9593\u6bce\u304f\u3089\u3044\u306b\u66f4\u65b0\u3059\u308b\u3088\u3046\u306b\u3057\u305f\u307b\u3046\u304c\u826f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<h3><span class=\"ez-toc-section\" id=\"%E5%8F%8D%E7%9C%81%E7%82%B9\"><\/span>\u53cd\u7701\u70b9<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>\u306f\u3066\u306a\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306e\u81ea\u5206\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af\u306e RSS \u306b\u306f\u30d6\u30c3\u30af\u30de\u30fc\u30af\u3057\u305f\u65e5\u6642\u306e\u60c5\u5831\u3082\u542b\u307e\u308c\u3066\u3044\u308b\u306e\u3067\u30011\u65e5\u5206\u3054\u3068\u306b &lt;h3&gt;2\u670815\u65e5\u306e\u30d6\u30c3\u30af\u30de\u30fc\u30af&lt;\/h3&gt; \u306e\u3088\u3046\u306a\u5c0f\u898b\u51fa\u3057\u3092\u4ed8\u3051\u305f\u304b\u3063\u305f\u306e\u3067\u3059\u304c\u3001simplexml_load_file() \u95a2\u6570\u3067\u306f<del datetime=\"2012-02-15T15:53:04+00:00\">\u65e5\u6642\u306e\u60c5\u5831\u306e\u90e8\u5206\u304c\u3046\u307e\u304f\u30d1\u30fc\u30b9\u3067\u304d\u306a\u3044\u3088\u3046\u3067\u3059<\/del>\u3002<\/p>\n<div class=\"a\">\n<h4>\u8ffd\u8a18<\/h4>\n<p><a href=\"http:\/\/www.amazon.co.jp\/gp\/product\/4774144371?ie=UTF8&#038;tag=caffeazzurro-22&#038;linkCode=shr&#038;camp=1207&#038;creative=8411&#038;creativeASIN=4774144371&#038;ref_=sr_1_2&#038;qid=1329321277&#038;sr=8-2\" target=\"_blank\">\u30d1\u30fc\u30d5\u30a7\u30af\u30c8PHP<\/a> \u306e\u8457\u8005\u3067\u3042\u308b @sotarok \u3055\u3093\u3088\u308a\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u30ea\u30d7\u3092\u9802\u304d\u307e\u3057\u305f\u3002<\/p>\n<blockquote class=\"twitter-tweet\" data-in-reply-to=\"169805253842186240\" lang=\"ja\">\n<p>@<a href=\"https:\/\/twitter.com\/Stocker_jp\">Stocker_jp<\/a> \u65e5\u4ed8\u306e\u90e8\u5206\u3092\u898b\u3064\u3051\u3089\u308c\u306a\u3044\u306e\u306f\u3001simplexml_load_file() \u304c\u30d1\u30fc\u30b9\u3067\u304d\u306a\u3044\u306e\u3067\u306f\u306a\u304f\u3001 dc:date \u306a\u3069\u3068\u540d\u524d\u7a7a\u9593\u4ed8\u304d\u306e XML \u30bf\u30b0\u3060\u304b\u3089\u3067\u3059\u306d\u3002 <a href=\"http:\/\/t.co\/zAYcwYVC\" title=\"http:\/\/bit.ly\/9QCFsk\">bit.ly\/9QCFsk<\/a><\/p>\n<p>&mdash; Sotaro KARASAWA\u00a9\u3055\u3093 (@sotarok) <a href=\"https:\/\/twitter.com\/sotarok\/status\/169806151733620737\" data-datetime=\"2012-02-15T15:31:56+00:00\">2\u6708 15, 2012<\/a><\/p><\/blockquote>\n<p><script src=\"\/\/platform.twitter.com\/widgets.js\" charset=\"utf-8\"><\/script><\/p>\n<p>\u3068\u3044\u3046\u308f\u3051\u3067\u3001\u540d\u524d\u7a7a\u9593\u306b\u3064\u3044\u3066\u8abf\u67fb\u3057\u3001\u65e5\u4ed8\u90e8\u5206\u3092\u53d6\u5f97\u3067\u304d\u308b\u3088\u3046\u6539\u826f\u3057\u307e\u3057\u305f\u3002<br \/>\n\u60c5\u5831\u63d0\u4f9b\u3044\u305f\u3060\u304d\u3001\u3042\u308a\u304c\u3068\u3046\u3054\u3056\u3044\u307e\u3057\u305f\u3002\n<\/p><\/div>\n<p>\u2026\u3068\u3044\u3046\u308f\u3051\u3067\u3001\u306f\u3058\u3081\u3066\u304a\u305f\u3088\u308a\u306b\u5fdc\u3048\u3066\u8a18\u4e8b\u3092\u66f8\u3044\u3066\u307f\u305f\u306e\u3067\u3059\u304c\u3001\u3053\u3093\u306a\u611f\u3058\u3067\u3088\u304b\u3063\u305f\u3067\u3057\u3087\u3046\u304b\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5148\u65e5\u3001\u3053\u3093\u306a\u304a\u305f\u3088\u308a\u3092\u9802\u304d\u307e\u3057\u305f\u3002 \u521d\u3081\u307e\u3057\u3066\u3001RSS\u306b\u767b\u9332\u3057\u3066\u3044\u3064\u3082\u52c9\u5f37\u3055\u305b\u3066\u3082\u3089\u3063\u3066\u307e\u3059\u3002 \u5148\u65e5\u306e\u8a18\u4e8b\u300c\u7ba1\u7406\u4eba\u306e\u65b0\u7740\u30d6\u30c3\u30af\u30de\u30fc\u30af\u3092\u898b\u308c\u308b\u30da\u30fc\u30b8\u3092\u4f5c\u308a\u307e\u3057\u305f | Stocker.jp \/ diary\u300d\u3092\u898b\u3066\u3068\u3066\u3082\u885d\u6483\u3092 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":6647,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[4],"tags":[9,22,12],"class_list":["post-1792","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-web","tag-php","tag-web","tag-12"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/stocker.jp\/diary\/wp-content\/uploads\/bm10-1.png?fit=500%2C300&ssl=1","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/posts\/1792","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/comments?post=1792"}],"version-history":[{"count":0,"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/posts\/1792\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/media\/6647"}],"wp:attachment":[{"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/media?parent=1792"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/categories?post=1792"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/stocker.jp\/diary\/wp-json\/wp\/v2\/tags?post=1792"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}