php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #54365 addslashes says that magic_quotes_gpc is on but it's not the case
Submitted: 2011-03-24 08:24 UTC Modified: 2011-03-24 08:40 UTC
From: shein@php.net Assigned:
Status: Wont fix Package: Documentation problem
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: shein@php.net
New email:
PHP Version: OS:

 

 [2011-03-24 08:24 UTC] shein@php.net
Description:
------------
---
From manual page: http://www.php.net/function.addslashes#Description
---
Fix the following paragraph because magic_quotes_gpc is off now by default:

The PHP directive magic_quotes_gpc is on by default, and it essentially runs 
addslashes() on all GET, POST, and COOKIE data. Do not use addslashes() on 
strings that have already been escaped with magic_quotes_gpc as you'll then do 
double escaping. The function get_magic_quotes_gpc() may come in handy for 
checking this.



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-03-24 08:36 UTC] aharvey@php.net
-Status: Open +Status: Wont fix
 [2011-03-24 08:36 UTC] aharvey@php.net
Depressingly, it's still on by default. (Check main/main.c in trunk if you don't believe me.)
 [2011-03-24 08:40 UTC] shein@php.net
Oops, sorry.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Mar 12 10:01:31 2025 UTC