ID:               37263
 Comment by:       judas dot iscariote at gmail dot com
 Reported By:      dbeckham at dealnews dot com
 Status:           Open
 Bug Type:         Scripting Engine problem
 Operating System: Linux (2.6.14)
 PHP Version:      5.1.2
 New Comment:

this is not a bug, it's a behaviour change of the engine.
see.

http://bugs.php.net/bug.php?id=35527

and the documentation here:

"Before PHP 5.1.1, backslash in \{$var} hasn't been printed."

"(Use "{\$" to get a literal "{$")." [1]

[1] http://php.net/manual/en/language.types.string.php


Previous Comments:
------------------------------------------------------------------------

[2006-05-01 15:36:29] dbeckham at dealnews dot com

Description:
------------
When escaping curly braces in a string, the backslash characters are
included in any output.

Reproduce code:
---------------
<?
$test = "test";
echo "\{$test\}\n";
?>


Expected result:
----------------
The above output should be:

{test}


Actual result:
--------------
The actual output is:

\{test\}



------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=37263&edit=1

Reply via email to