Category
show
전체 (775)
웹표준, 웹접근성™ (5)
웹프로그래밍™ (360)
웹기획™ (0)
웹디자인™ (5)
서버™ (32)
데이터베이스™ (43)
개발자료 (9)
트랜드 (60)
Study English (2)
블루비 (70)
오피스 다이어리 (19)
Textcube (2)
이슈 (20)
컴퓨터 악세사리 (18)
엔터테인먼트 (24)
좋은글 (73)
재테크 (1)
이벤트 (4)

디렉코리 명 추출 함수

웹프로그래밍™/PHP, ASP, JSP, JAVA 2005/08/27 22:46 by 블루비 Total 357 : Today 3 : Yesterday 0
특정 디렉토리안의 서브디렉토리를 추출할 때 사용

function get_dir($dir)
{

if (is_dir($dir))
{

if ($dh = opendir($dir))
{

while (($file = readdir($dh)) !== false)
{

if ($file != "." && $file != "..")
{

if( is_dir("$dir/$file") )
{
get_dir("$dir/$file");//recall
}

$list[$i] = $file;
$i++;
}
}//end while
closedir($dh);
}
}
}//end open_dir()

get_dir("dir_path");
?>
2005/08/27 22:46 2005/08/27 22:46

TRACKBACK :: http://blueb.net/blog/trackback/36

Leave a Comment
[로그인][오픈아이디란?]
1  ... 751 752 753 754 755 756 757 758 759  ... 775 

달력

«   2008/11   »
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30