{"id":685,"date":"2011-04-08T01:38:48","date_gmt":"2011-04-07T16:38:48","guid":{"rendered":"http:\/\/blog.t-szk.com\/?p=685"},"modified":"2011-04-08T01:38:48","modified_gmt":"2011-04-07T16:38:48","slug":"php%e6%8c%87%e5%ae%9a%e3%81%97%e3%81%9f%e3%83%87%e3%82%a3%e3%83%ac%e3%82%af%e3%83%88%e3%83%aa%e3%81%ae%e3%83%95%e3%82%a1%e3%82%a4%e3%83%ab%e4%b8%80%e8%a6%a7%e3%82%92%e5%8f%96%e5%be%97%e3%81%99","status":"publish","type":"post","link":"https:\/\/codaholic.org\/?p=685","title":{"rendered":"[PHP]\u6307\u5b9a\u3057\u305f\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306e\u30d5\u30a1\u30a4\u30eb\u4e00\u89a7\u3092\u53d6\u5f97\u3059\u308b"},"content":{"rendered":"<p>\u7279\u5b9a\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306b\u542b\u307e\u308c\u3066\u3044\u308b\u30d5\u30a1\u30a4\u30eb\u4e00\u89a7\u3092\u53d6\u5f97\u3059\u308b\u30b3\u30fc\u30c9\u3067\u3059\u3002<\/p>\n<p>[php]<br \/>\n<?php\n\t$dir = '.\/images\/';\n\t$dh = opendir($dir);\n\n\t$fnArray = array();\n\twhile(false !== ($fn = readdir($dh))){\n\t\tif($fn !== '.' &#038;&#038; $fn !== '..' &#038;&#038; !is_dir($dir.$fn)){\n\t\t\tarray_push($fnArray, $fn);\n\t\t}\n\t}\n\tclosedir($dh);\n\n\tprint_r($fnArray);\t\n?><br \/>\n[\/php]<\/p>\n<p>3\u884c\u76ee<br \/>\n\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u30cf\u30f3\u30c9\u30eb\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<p>6\u884c\u76ee<br \/>\nreaddir\u95a2\u6570\u3092\u4f7f\u7528\u3057\u3066\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002readdir\u95a2\u6570\u306f\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u5168\u3066\u53d6\u5f97\u3057\u305f\u3089false\u3092\u8fd4\u3057\u307e\u3059\u304c\u3001false\u4ee5\u5916\u306b\u30820\u3084\u7a7a\u6587\u5b57\u3092\u8fd4\u3059\u53ef\u80fd\u6027\u304c\u3042\u308b\u306e\u3067\u3001false\u3068\u53b3\u5bc6\u306a\u6bd4\u8f03\u3092\u884c\u3046\u3079\u304d\u3067\u3042\u308b\u3068<a href=\"http:\/\/jp2.php.net\/manual\/ja\/function.readdir.php\" target=\"_blank\">\u30de\u30cb\u30e5\u30a2\u30eb<\/a>\u306b\u3042\u308a\u307e\u3057\u305f\u3002<\/p>\n<p>7\u884c\u76ee<br \/>\nreaddir\u95a2\u6570\u304c\u8fd4\u3059\u5024\u306b\u306f\u300c.\u300d\u3068\u300c..\u300d\u304c\u542b\u307e\u308c\u307e\u3059\u3002\u307e\u305f\u3001\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u540d\u3082\u8fd4\u3055\u308c\u308b\u306e\u3067\u8fd4\u3055\u308c\u305f\u5024\u304c\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u540d\u3067\u306a\u3044\u304b\u5224\u5225\u3057\u307e\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u7279\u5b9a\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306b\u542b\u307e\u308c\u3066\u3044\u308b\u30d5\u30a1\u30a4\u30eb\u4e00\u89a7\u3092\u53d6\u5f97\u3059\u308b\u30b3\u30fc\u30c9\u3067\u3059\u3002 [php] [\/php] 3\u884c\u76ee \u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u30cf\u30f3\u30c9\u30eb\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002 6\u884c\u76ee readdir\u95a2\u6570\u3092\u4f7f\u7528\u3057\u3066\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002readdir\u95a2\u6570\u306f\u30d5 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","jetpack_publicize_message":"","jetpack_is_tweetstorm":false,"jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[4],"tags":[244,131],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p8gd1W-b3","_links":{"self":[{"href":"https:\/\/codaholic.org\/index.php?rest_route=\/wp\/v2\/posts\/685"}],"collection":[{"href":"https:\/\/codaholic.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/codaholic.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/codaholic.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/codaholic.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=685"}],"version-history":[{"count":3,"href":"https:\/\/codaholic.org\/index.php?rest_route=\/wp\/v2\/posts\/685\/revisions"}],"predecessor-version":[{"id":688,"href":"https:\/\/codaholic.org\/index.php?rest_route=\/wp\/v2\/posts\/685\/revisions\/688"}],"wp:attachment":[{"href":"https:\/\/codaholic.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=685"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/codaholic.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=685"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/codaholic.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=685"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}