Check if the completed email already exists in the PHP database

Asked

Viewed 172 times

-1

Not being able to register or check the emails,inserir a descrição da imagem aqui be able to help....

1 answer

0


In your first query try...

$check = mysqli_query("SELECT * FROM registration Where email = '$emailc');

email: replace by the name in your bank.

$emailc: I believe this is the email you sent to register....

I removed Limit 1 because this query searches the bank to register with this email if it finds, yes it will search for more than one if you do not put the email as the only one in the bank and have more than one register with same email, how you want it to be unique change it in the bank not to accept equal email registration.

Anyway change in the bank the email to only already solves your problem maybe taking away the need to check if it has in the bank before including another registration, because it as only when trying to insert a registration would return an error.

  • You’re logging the emails, only you’re logging repeat emails,...=/

  • as I said and just go to the bank and change your email column to single, so he did not accept to insert repeated emails.

  • worked out, the prolema was the version of WAMP, vlw mano

Browser other questions tagged

You are not signed in. Login or sign up in order to post.