Escape MySQL dangerous symbols
Hello everybody.
I've created simple SQL logger, to log all chat and actions. Certainly i noticed that few events doesn't appear in MySQL database. The reason of that, was the ' symbol, which acts as delimiter in the insert command. My part of plugin looks that way PHP Code:
Is there a good way to escape "all" dangerous symbols in nicknames and messages before insert statement? Thanks! |
Re: Escape MySQL dangerous symbols
You should use:
PHP Code:
|
Re: Escape MySQL dangerous symbols
Thanks!
|
| All times are GMT -4. The time now is 08:11. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.