Why is using a mysql prepared statement more secur

2019-01-02 21:25发布

There's a comment in another question that says the following:

"When it comes to database queries, always try and use prepared parameterised queries. The mysqli and PDO libraries support this. This is infinitely safer than using escaping functions such as mysql_real_escape_string."

Source

So, what i want to ask is: Why are prepared parameterized queries more secure?

7条回答
何处买醉
2楼-- · 2019-01-02 21:58

Very best case, it might not be, but it's at least equally safe; and why take the chance?

查看更多
登录 后发表回答