<table cellspacing="0" cellpadding="0"><tr><td class="t_f" id="postmessage_61068"> <div class="blockcode"> <div id="code_X49"><ol> <li><?php<li>$dir = "PUT_PATH_TO_DIR_HERE";<li><li>// Open a known directory, and proceed to read its contents<li>if (is_dir($dir)) {<li> if ($dh = opendir($dir)) {<li> while (($file = readdir($dh)) !== false) {<li> echo "filename: $file : filetype: " . filetype($dir . $file) . "n";<li> }<li> closedir($dh);<li> }<li>}<li>?></li> <li> </ol></div> <em onclick="copycode($('code_X49'));">复制代码</em> </div> <br> </td></tr></table> <div class="ptg mbm mtn"> 디렉토리, PHP</div> <div id="comment_61068" class="cm"> </div> <div id="post_rate_div_61068"></div> <br><br>