This is a discussion on what is wrong with this <<< syntax ?? within the PHP Language forums, part of the PHP Programming Forums category; Ok, pretty new to this php stuff, but good with perl/python etc. What is wrong with this php document ??? ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Ok, pretty new to this php stuff, but good with perl/python etc.
What is wrong with this php document ??? I get this error: Parse error: syntax error, unexpected $end in E:\xampp\workspace\test1\fragments.php on line 7 from this doc ... ===== start doc <? print <<<EOF asdf EOF; print <<<EOFX asdf EOFX; ?> ===== end doc |
|
|||
|
On 25 Mar 2005 07:39:44 -0800, "andrew" <aktweb@msn.com> wrote:
>Ok, pretty new to this php stuff, but good with perl/python etc. > >What is wrong with this php document ??? > >I get this error: > >Parse error: syntax error, unexpected $end in >E:\xampp\workspace\test1\fragments.php on line 7 > >from this doc ... > >===== start doc ><? >print <<<EOF >asdf >EOF; > > >print <<<EOFX >asdf >EOFX; >?> >===== end doc Nothing's wrong with what you've posted, it works fine. -- Andy Hassall / <andy@andyh.co.uk> / <http://www.andyh.co.uk> <http://www.andyhsoftware.co.uk/space> Space: disk usage analysis tool |
|
|||
|
andrew wrote:
> > What is wrong with this php document ??? > > I get this error: > > Parse error: syntax error, unexpected $end in > E:\xampp\workspace\test1\fragments.php on line 7 > > from this doc ... > > ===== start doc > <? > print <<<EOF > asdf > EOF; > > print <<<EOFX > asdf > EOFX; > ?> > ===== end doc Make sure EOF; and EOFX; are immediately followed by line breaks (there should not be any blank spaces after them). Cheers, NC |