Jump to content

Recommended Posts

Some members on my site have been getting SQL errors from entries if they use any special characters (' " \, etc). For sake of example, say $entry is a variable declared to hold the value of an entry. How can I adjust $entry so that any special characters will be put into the database correctly without error.

Link to comment
https://forums.phpfreaks.com/topic/62834-some-form-entries-cause-sql-error/
Share on other sites

This isn't just a matter of nice output, but also security.

 

Lots of people found out the hardway that you can inject SQL commands into form data very easily and retrieve admin passwords, delete tables etc. etc. if it isn't screened before being put into the SQL command

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.