Go4Expert (http://www.go4expert.com/)
-   PHP (http://www.go4expert.com/forums/php/)
-   -   extremely basic question - php (http://www.go4expert.com/forums/extremely-basic-question-php-t27996/)

kylexy 11Mar2012 20:31

extremely basic question - php
can somebody explain me heredoc and newdoc syntax in a few words please ?
i know it's so basic but since i have no idea ... it's hard 4 me. :embarasse
it'd be extremely helpful to understand this...

brillcareer 27May2015 12:07

Re: extremely basic question - php
hi Kylexy

here is the syntax for heredoc
$str = <<<DEMO
This is a
demo message
with heredoc.

echo $str;

alia123 13Jan2016 18:28

Re: extremely basic question - php
Nowdocs are to single-quoted strings what heredocs are to double-quoted strings. A nowdoc is specified similarly to a heredoc, but no parsing is done inside a nowdoc.
Here’s a link I’m sharing check this for more details” http://lindensgarden.blogspot.in/200...redoc-and.html

All times are GMT +5.5. The time now is 00:26.