You are here: Re: HEREDOC help, going quietly nuts « PHP Programming Language « IT news, forums, messages
Re: HEREDOC help, going quietly nuts

Posted by Rik Wasmus on 10/20/07 17:06

On Sat, 20 Oct 2007 17:44:48 +0200, bill <nobody@spamcop.net> wrote:

> with this code:
> ------------------------------------------
> $sql =3D "select * from do_be_do where do_be_id =3D '$GET[id]' limi=
t 1";
> $result =3D mysql_query($sql, $connection) or die (mysql_error());
> $row =3D mysql_fetch_array ($result);
> =

> $title =3D stripslashes($row['title']);
> $depends =3D stripslashes($row['depends']);
>
> $detail<<<eoxd
> <form action=3D"do_detail_save.php" method=3D"post">
> ...
> eoxd;
> ----------------------------
> (the elipses (...) represent code left out of the posting
>
> I get the compile error:
> Parse error: syntax error, unexpected T_START_HEREDOC in ....at line 5=
4.
>
> line 54 is the line after: $detail<<<eoxd
>
> I can't see an error.

Think of heredoc as alternative quotes

What would the error be in:
$detail 'foo';
-- =

Rik Wasmus

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация