php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #2389 addslashes make a mistake when there are digits after \
Submitted: 1999-09-27 09:07 UTC Modified: 1999-09-27 13:22 UTC
From: alevine at db-soft dot it Assigned: jah (profile)
Status: Closed Package: Documentation problem
PHP Version: 3.0.9 OS: Linux Slackware 3.6
Private report: No CVE-ID: None
 [1999-09-27 09:07 UTC] alevine at db-soft dot it
$Path=addslashes("\123moon\year\one");

The result will be:
Smoon\\year\\one

Compiled with mysql


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1999-09-27 12:41 UTC] jah at cvs dot php dot net
Within double quotes, strings matching regexp \[0-7]{1,3} are considered to be
octal numbers, likewise strings matching regexp \x[0-9A-Fa-f]{1,2} are
considered to be hexadecimal numbers. Use single quotes.

Bug reclassified as documentation problem (until fixed).
 [1999-09-27 13:22 UTC] jah at cvs dot php dot net
Fixed in the docs.
 [2020-02-07 06:12 UTC] phpdocbot@php.net
Automatic comment on behalf of jah
Revision: http://git.php.net/?p=doc/en.git;a=commit;h=de48047a5d812ac729341279c0d329ae0b66ec7a
Log: Fix #2389.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Jun 16 03:01:28 2024 UTC