Added to add_reg.php: Script now checks if variables exist or if they are empty strings (with isset() and empty() functions respectively) before trying to insert to DB. If any required fields are empty it prints an error message saying so and doesn't try to push data to DB. It also checks if the string value returned when trying to do an INSERT INTO query is an empty string (denoting a successful operation) or is not empty (operation failed). If the query was successful it prints a message saying so, if the query failed it also says so, and additionally prints the error string returned.