**** PLEASE USE THE CODE TAG WHEN POSTING *****
Code: Select all
$myFile = "details.txt";
$fh = fopen($myFile, 'a') or die("can't open file");
$stringData = $fname. "\t".$lname. "\t".$phone. "\t".$positiontype. "\t".$details. "\t".$education. "\t".$TofD."\n";
fwrite($fh, $stringData);
fclose($fh);If the input in the text area is typed all as one sentence, I dont have this problem.
Can anyone help???
Code: Select all
echo "<table border=1 bgcolor = \"#000000\" bordercolor = \"#333333\"> \n";
echo "<tr><th>First Name</td>
<th>Surname</td>
<th>Phone No</td>
<th>Position Type</td>
<th>Details</td>
<th>Education</td>
<th>Time of Day to Contact</td>
</tr>";
for ($i=0; $i<$number_posts; $i++)
{
//split the lines
$line = explode ( "\t", $test[$i] );
echo "<tr><td>$line[0]</td>
<td>$line[1]</td>
<td>$line[2]</td>
<td>$line[3]</td>
<td>$line[4]</td>
<td>$line[5]</td>
<td>$line[6]</td>
</tr>";
}
echo "</table>";
?>