标签:
header("Content-type:text/html;charset=utf-8"); function reddir($path,$level=0) { $dh = opendir($path); while(($row = readdir($dh)) !== false) { if($row == ‘.‘ || $row == ‘..‘) continue; echo str_repeat(‘ ‘,$level*6) . $row . ‘<br />‘; if(is_dir($path . ‘/‘ . $row)) reddir($path . ‘/‘ . $row , $level+1); } closedir($dh); } reddir($path);
标签:
原文地址:http://www.cnblogs.com/chenqionghe/p/4230900.html