ID:               5007
 Updated by:       [EMAIL PROTECTED]
 Reported By:      waldschrott at kiffen dot de
-Status:           Analyzed
+Status:           Closed
 Bug Type:         Feature/Change Request
 Operating System: all
 PHP Version:      4.0 Latest CVS (13/06/2000)
 New Comment:

This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.

Yes, 5.3 implements such a feature.


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

[2008-10-07 10:27:31] mark at hell dot ne dot jp

I believe this feature request can now be closed (with PHP 5.3.0).

http://fr.php.net/language.types.string#language.types.string.syntax.nowdoc

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

[2000-08-28 01:49:53] [EMAIL PROTECTED]

in addition we could make here-docs structured code friendly by adding
sth. like a parameter (don´t know where,maybe <<<3"MARK")
indicationg how many tabs are prepended, thus the above would render
echo <<<3"MARK"
\t\t\tHello
\t\t\tMr. Foobar
\t\t\t\tTest
MARK;
as

Hello
Mr. Foobar
\tTest

and not with these redundant 3*\t´s in front of every line

then users can user here-docs in classes and functions *without*
crippling their code to ugliness  

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

[2000-07-08 10:49:48] waldschrott at kiffen dot de

--<cut>--
The format of here-documents is as follows:

          <<[-]word
                        here-document
          delimiter

No parameter expansion, command  substitution,  arithmetic
expansion, or pathname expansion is performed on word.  If
any characters in word are quoted, the  delimiter  is  the
result  of  quote  removal  on  word, and the lines in the
here-document are not expanded.  If word is unquoted,  all
lines  of  the  here-document  are  subjected to parameter
expansion, command substitution, and arithmetic expansion.
In  the  latter case, the character sequence \<newline> is
ignored, and \ must be used to quote the characters \,  $,
and `.

If  the  redirection operator is <<-, then all leading tab
characters are stripped from  input  lines  and  the  line
containing  delimiter.   This allows here-documents within
shell scripts to be indented in a natural fashion.
--<cut>--  


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

[2000-06-13 19:22:54] waldschrott at kiffen dot de

Perl has <<"MARK" and <<'MARK' (as Stas told me),
it would be handy for PHP too...
I think sample code isn´t need, because it´s an existing feature in
Perl core devolpers know of.


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


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

Reply via email to