![]() |
Anybody know what causes this error in MySQL
When users try to add a listing by typing into a text box and they use any word with a ' so if they type sort's it comes up saying that there is an error in MySQL
Anbody know what causes this or how to fix it cheers |
|
what is the error?
|
Quote:
|
Quote:
|
you need to "clean up" your variables by escaping those things that causes mysql to throw up.
$insertthisnowtomysql = mysql_real_escape_string($sometextforinsert) now just run "INSERT" sql |
Quote:
|
its the ' use " instead
|
like someone said earlier, just escape the input before putting it in the db...
but that error isn't just some inconvenience, it can often be exploited to hack the script... I would have someone look into it... |
Quote:
|
Quote:
http://www.embracer.com/2009/databas...sql-injections |
Quote:
Im not very good when it comes to mysql things and Im not to sure what he means by " just escape the input before putting it in the db... is this inserted into the database or the script If I cant fix it I will see if sands is about and see if he can fix it or contact the people I bought the script from |
Quote:
|
|
Quote:
|
All times are GMT -7. The time now is 02:53 AM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123