Hi All,
Firstly I must say I have had some great help of Bubblenut and I thank him for that.
My problem now is simple "I think" but I just cannot get my head around it.
I have my code which produces the correct data, now I need to make the output presentable to the user.
The current output produces the following:
staff_position column and staff_name column.
The first staff_name to be found by the query is output to the right of the column header but is squashed up.
The second and third staff_names are output to a new line under the staff_position column header. I want the second and third and so one to be output under the first staff_name.
In simple terms I want a column for the staff_position and a column for the staff_name.
The code I am using is;
while($row = mysql_fetch_assoc($res)) {
if($current_position!=$row['staff_position']) {
echo("<tr><td><h3>Position: ".$row['staff_position']."</h3></td>");
$current_position=$row['staff_position'];
}
echo("<td width=\"400\"><h2>Staff Name: ".$row['staff_name']."</h2></td></tr>");
}
Bubblenut told me to work this out for myself, and he is right to say that. But I have been working on this for an age.
Can anyone help.