M
M
minerva-bk2012021-04-01 22:45:00
Knowledge base
minerva-bk201, 2021-04-01 22:45:00

(fixed) Data is not added to the database (registration) What is the problem?

Previously, the code worked, but recently the registration stopped working, what could be the problem? I can't fix it at all.
(fixed

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
rPman, 2021-04-02
@rPman

check each mysqli call for an error, passing it to the client, the answer is
ps do not shove the values ​​received from the client into the query string, use prepared statements otherwise you will get a sql injection attack
as an alternative, carefully check all incoming parameters for valid characters, cutting off quotes and backticks slash
pps don't use mysqli this library can only work with mysql, it's better to use PDO, it's more versatile and supports more databases

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question