php - How to insert `>` and `(` into MySQL? -


I do not know where the problem is that I & gt; and ( in my MySQL database).

I add a addslashes ($ str) , but it can still leave the quotation marks unsecured.

Is there any string functions that can solve my problem?

, use ...

every Once you exit the string in a query, use it!

... or better, use a binded parameter with something like PDO.

By the way, there is no reason why & gt; and ) will be inserted into your database which I can think of, without any meaning inside the string \ .



Comments