Forum Moderators: open
While in other references, it is said that addslashes is not enough and that mysql_escape_string should be used.
Lastly, it is also said that using addslashes is better for its compatibility and possibility to work with multiple database type.
So what is best?
Additionally, addslashes has been removed from php6. So to future-proof your code you'd want to use mysql_real_escape_string.