|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-03-26 12:39 UTC] dmitry@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Nov 21 14:00:02 2025 UTC |
Description: ------------ why nowdoc can not be embed in heredoc but can be embed in double quote? Why the second paragraph is right(using double quote), while the commented is not right(using nowdoc)? <? $s='substr'; /* $htm=<<<DOC {$s(<<<'ppp' abcdefg ppp ,0,3)} DOC; */ $htm=" {$s(<<<'ppp' abcdefg ppp ,0,3)} "; echo $htm; ?> Expected result: ---------------- Output 'abc' Actual result: -------------- Output: Parse error: parse error, expecting `'}''