I have this PHP
loop
:
foreach($_POST['af_break_date'] as $id=>$value) {
$update_break_date_query = "UPDATE studentdates SET student_break_date = '$value' WHERE student_date_id = '$id';";
$update_break_date_sql = mysql_query($update_break_date_query) or die(mysql_error());
}
I want to run the $update_break_date_sql
only if each $_POST['af_break_date']
is not null.
How can this be done?