I had found the solution.
.
.
.
$path = "..."; $theFilePath = "";
$theFileName = glob ($path . "*.xls");
for($j = 0; $j< count($theFileName); $j++) {
$theFilePath = $theFileName[$j];
$excel = new Spreadsheet_Excel_Reader();
$excel->setOutputEncoding('CP1251');
$excel->setUTFEncoder('mb_convert_encoding');
error_reporting(E_ALL ^ E_NOTICE);
echo "<br />";
echo $theFilePath;
echo "<br />";
$excel->read($theFilePath);
.
.
.
}
while putting the path inside for loop, it can loop through all file inside the folder