stripslashes and database

If magic_quotes_runtime=Off, you will need to use stripslashes() on strings you pull out of a database. Remember that data stored in a MySQL database is escaped; and, therefore, must be unescaped when it comes out.

Use get_magic_quotes_runtime() to find out if magic_quotes_runtime is Off or On. This function returns 0 if Off and 1 otherwise.

Advertisements

About samehramzylabib

See About on https://samehramzylabib.wordpress.com
This entry was posted in PHP stripslashes and addslashes and tagged , , , . Bookmark the permalink.

Comment

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s