>    >    
" size="40">
'; // browse pages subdirectory browse_pages_dir($phpwcms['content_path'].'pages'); function browse_pages_dir($dir) { $pc = 0; $da = array(); //directory array $fa = array(); //file array if(is_dir($dir)) { $ph = opendir($dir); while($pf = readdir($ph)) { if($pf != '.' && $pf != '..') { if(is_dir($dir.'/'.$pf)) { $da[] = $pf; //add $pf to folder array for current dir } else { if( preg_match('/(\.html|\.htm|\.txt|\.php|\.inc|\.tmpl)$/', strtolower($pf)) ) { $fa[] = $pf; //add $pf to file array for current dir } } } } closedir($ph); // list files if(count($fa)) { $x = 0; foreach($fa as $value) { if(!$x) { echo "\n"; echo '  '.html_specialchars($dir); echo "\n"; echo ''; } echo "\n"; echo ''; echo ''; echo str_replace(' ', ' ', html_specialchars($value)); echo ''; $x++; } echo ''; } // check all subdirs if(count($da)) { foreach($da as $value) browse_pages_dir($dir.'/'.$value); } } } echo "\n"; echo ''; echo "\n"; ?>