1.方法一:复制代码 代码如下:<? $dir=”D:”; static $dir_list =0; static $file_list =0; function listfile($dir){global $dir_list,$file_list;$d = dir($dir); while ( $entry = $d->read()) { $tem_curnt=$dir.”/”.$entry; if($entry==”.” || $entry==”..”) continue; if ( is_dir( $tem_curnt)) { listfile($tem_c