Here is the contents of the txt files:
QUOTE
11/18/2005,3:01:49 AM, 74.25
11/18/2005,3:11:49 AM, 74.37
11/18/2005,3:21:51 AM, 74.37
11/18/2005,3:31:53 AM, 74.37
Here is my PHP
QUOTE
<form method=get action=index2.php><select name='selected_file'>
<?php
$mydir = dir('E:\SoundFX\temperature\logfiles');
while(($file = $mydir->read()) !== false) {
echo "<option value='$file'>$file<BR>";
}
echo "</select><INPUT TYPE=SUBMIT VALUE='Select'></form>";
$the_file =$_GET['selected_file'];
echo $the_file;
if ($the_file !="")
{
$fp = @fopen("$the_file", "rb") or die("Couldn't open file");
$data = fread($fp, filesize($fp));
while(!feof($fp))
{
$data .= fgets($fp, 1024);
}
fclose($fp);
$values = explode("\r\n", $data);
//echo substr($values[1],0);
foreach($values as $current_value)
{
echo substr($current_value,0)."<br>";
}
}//end if
?>
Any suggestions?