指定したフォルダー内の全ファイル名を取得する

指定したフォルダー内の全ファイル名を取得する

	chdir($temp_folder);
	$dh = opendir(".");
	rewinddir ($dh);

	while (($tempfile = readdir($dh))){
		if (is_file($tempfile)) {
			$all_files[] = urldecode(mb_convert_encoding($tempfile,"utf-8","sjis"));
		}
	}

	closedir($dh);

コメント

タイトルとURLをコピーしました