I have a simple database(test) with the table users; Under users I have columns user,idNum, password. When creating a registration form to add a new user I encounter an error that the username being set is the column it is looking for.
$conn = mysqli_connect("localhost", "root", ' ', "test");
$query = "INSERT INTO users (user, idNum, password) VALUES($user, &id, $password)";
$result = mysqli_query($conn,$query);
The result variable is always false and get I the column error for whatever the name I put into the username field in my HTML form.