I have had some fsntastic assistance with this but I am getting an error message on line 109:
foreach($qualsys_array as $qualsys){
echo ('<input type="checkbox" name="qualsys_checkbox[]" value="".$qualsys['quality_system_id']."">".$qualsys['quality_system']."');
}
here is my code in in its entirerity
<?php
include ("connect.php");
// Get the quality systems
$sql_qualsys = "SELECT * FROM quality_systems ORDER by quality_system";
$qualsys_result = mysql_query($sql_qualsys) or die("Error fetching quality systems: ".mysql_error());
$qualsys_array = mysql_fetch_assoc($qualsys_result);
// Get the expertise
$sql_expert = "SELECT * FROM expert_participant ORDER by expert";
$expert_result = mysql_query($sql_expert) or die("Error fetching experts: ".mysql_error());
$expert_array = mysql_fetch_assoc($expert_result );
// Get the activities
$sql_activity = "SELECT * FROM activity_participant ORDER by activity";
$activity_result = mysql_query($sql_activity) or die("Error fetching activities: ".mysql_error());
$activity_array = mysql_fetch_assoc($activity_result);
echo ('<form name="searchform" method="GET" action="search.php">
<table>
<tr>
<td>Select the quality systems:</td>
</tr>
<tr>
<td>');
foreach($qualsys_array as $qualsys){
echo ('<input type="checkbox" name="qualsys_checkbox[]" value="".$qualsys['quality_system_id']."">".$qualsys['quality_system']."');
}
echo ('</td>
</tr>
<tr>
<td>Select the expertise:</td>
</tr>
<tr>
<td>');
foreach($expert_array as $expert){
echo ('<input type="checkbox" name="expert_checkbox[]" value="".$expert['expert_participant_id']."">".$expert['expert']."');
}
echo ('</td>
</tr>
<tr>
<td>Select the activities:</td>
</tr>
<tr>
<td>');
foreach($activity_array as $activity){
echo ('<input type="checkbox" name="activity_checkbox[]" value="".$activity['activity_participant_id']."">".$activity['activity']."');
}
echo ('</td>
</tr>
<tr>
<td>
<input type="submit" name="search_submit" value="Search!">
</td>
</tr>
</table>');
?>
many thx in advance