PHPの関数の戻り値について
<!-- Code highlighting produced by Actipro CodeHighlighter (freeware) http://www.CodeHighlighter.com/ -->function Traverse_files($dir1,$dir2){ $dir = $dir1.'/'.$dir2; //print $dir; //exit; $ss = array(); if (is_dir($dir)){ if ($dh = opendir($dir)){ while (($file = readdir($dh)) !== false){ if($file!=="."&& $file!==".."){ $ss[]=$file; } } print_r($ss); return $ss; closedir($dh); } } } $dirbase = 'd:'; $dirito = '5-24'; $bb = Traverse_files($dirbase,$dirito); printf($bb);