php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #42457 PHP directive magic_quotes_sybase not getting enabled in php6 by ini_set() func
Submitted: 2007-08-28 10:42 UTC Modified: 2007-08-28 20:38 UTC
From: nikhil dot gupta at in dot ibm dot com Assigned:
Status: Not a bug Package: Strings related
PHP Version: 6CVS-2007-08-28 (CVS) OS: linux, windows
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 this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: nikhil dot gupta at in dot ibm dot com
New email:
PHP Version: OS:

 

 [2007-08-28 10:42 UTC] nikhil dot gupta at in dot ibm dot com
Description:
------------
On using ini_set() function to enable PHP directive magic_quotes_sybase, we get bool(false) and directive is not enabled. This behaviour is seen only for php6. On php5, directive gets enabled using ini_set().

Reproduce code:
---------------
<?php
$str = "how're you?";
var_dump( addslashes($str) );

// turn on PHP directive magic quotes sybase

var_dump( ini_set("magic_quotes_sybase", "1") );
var_dump( addslashes($str) );
?>


Expected result:
----------------
string(12) "how\'re you?"
string(1) "0"
string(12) "how''re you?"


Actual result:
--------------
string(12) "how\'re you?"
bool(false)
string(12) "how\'re you?"


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-08-28 20:27 UTC] judas dot iscariote at gmail dot com
Expected behaviuor. all magic_quotes_* functionality has been removed from PHP6, you really dont want this damn magic_quotes_* thing ;)
 [2007-08-28 20:38 UTC] derick@php.net
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 18 08:02:42 2024 UTC