All pastes #928647 Raw Edit

Untitled

public php v1 · immutable
·published 2008-03-05 05:34 UTC
rendered paste body
$string="";$fileCount=0;$filePath=$PATH.'/var/www/public_html/'; # Specify the path you want to look in. $dir = opendir($filePath); # Open the pathwhile ($file = readdir($dir)) {   if (eregi("\.htm",$file)) {    $string .= "$file<br />";    $fileCount++;  }}