如何用PHP判断一个文件夹是否为空

如题所述

$a=array_diff(scandir($dir),array('..','.'));
//数组为空代表文件夹为空

温馨提示:内容为网友见解,仅供参考
无其他回答
相似回答