many thanks for your reply devinemke but I cannot get this to work
$query = "INSERT INTO tenant_details (surname, firstname, sex, dob, landlordloid, date) VALUES ('','$last','$first','$male','$dob','$landlordloid',NOW())";
I have tried
$query = "INSERT INTO tenant_details (surname, firstname, sex, dob, landlordloid, date) VALUES ('','$last','$first','$sex','$dob','$landlordloid','NOW()')";
But this does not work either. i will keep trying, many thanks roscor