$value) { print "1"; if($key == "id") continue; if($key == "action") continue; if($key == "submit") continue; $KEYS[] = "$key"; $VALUES[] = "'$value'"; } $sql="insert into vehicles (".implode(" ,", $KEYS).") VALUES (".implode(" ,", $VALUES).")"; #print $sql; #exit(0); DatabaseExecute($sql)or die(mysql_error()); header("location:index.php"); print "Record Added"; } if(isset($_POST['action']) && $_POST['action']=="update") { $id = $_POST['id']; foreach($_POST as $key=>$value) { if($key == "id") continue; if($key == "action") continue; if($key == "submit") continue; $sql="update vehicles set $key = '$value' where id = $id"; #print $sql; DatabaseExecute($sql)or die(mysql_error()); } #exit(0); header("location:index.php"); } ?>
Make

Make
Model
Year
Battery
Ignition
Start
Horn
Indicators
Notes
" .$row['make']." " .$row['model']." " .$row['year']. "
Battery -".$row['batt']. "
Ignition -".$row['ign']. "
Start -".$row['start']. "
Horn - ".$row['horn']. "
Indicators -".$row['indicators']. "
Notes -".$row['notes']. "

"; } } ?>

Make
Model
Year
Battery
Ignition
Start
Horn
Indicators
Notes