Home  >  Article  >  Backend Development  >  How to set escape in php.ini

How to set escape in php.ini

藏色散人
藏色散人Original
2021-09-21 11:18:592740browse

How to set escape in php.ini: 1. Find and open the php.ini configuration file; 2. Modify the "magic_quotes_gpc" and "magic_quotes_runtime" options to "On".

How to set escape in php.ini

The operating environment of this article: Windows 7 system, PHP version 7.1, Dell G3 computer.

How to set escaping in php.ini?

php.ini sets automatic escaping of submitted data

There are two first selections in php.ini to control automatic escaping

magic_quotes_gpc:自动转义GET/POST/COOKIES
magic_quotes_runtime:自动转义SQL

Default these two The option is "On", set "Off" to turn it off. If you don't want to modify the configuration, you can use stripcslashes to unescap the automatically escaped string.

Recommended learning: "PHP Video Tutorial"

The above is the detailed content of How to set escape in php.ini. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn