Re: [PHP] Re: unexpected T_SL

2002-09-02 Thread Voisine

I tried everything and I still have this error. I have this error with  php 4.2.2
on Windows 98  I also have the same problem with Apache, RedHat php 4.2.1.
WellI'm going to skip this lesson.

Thanks for all the help!

Regards!


Steel wrote:

> Hi Erwin,
>
> Monday, September 2, 2002, 11:28:09 AM, I've got:
>
> E> Voisine wrote:
> >> Hi,
> >>
> >> What is wrong witht his code? Parse error: parse error, unexpected
> >> T_SL in c:\program files\easyphp\www\tutorial\eod.php on line 2
> >>
> >>  >> $str = << >> Example of string
> >> spanning multiple lines
> >> using heredoc syntax.
> >> EOD;
> >> ?>
>
> E> To be honest, there is nothing wrong. It works in version 4.2.2 (at least,
> E> here it does) ;-))
>
> E> Grtz Erwin
>
> Why not to try
>  $str = <<< EOT
> ???
>
> It seems to me, that EOD  -> End Of Data, and EOT -> End Of Text
>
> Silly, but why not to try? :)
>
> --
> The Same,
>  Steelmailto:[EMAIL PROTECTED]
>http://www.none.ru


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Re: unexpected T_SL

2002-09-02 Thread Chris Hewitt

>
>
>>Voisine wrote:
>>Hi,
>>
>>What is wrong witht his code? Parse error: parse error, unexpected
>>T_SL in c:\program files\easyphp\www\tutorial\eod.php on line 2
>>
>>>$str = <<>Example of string
>>spanning multiple lines
>>using heredoc syntax.
>>EOD;
>>?>
>>
Assuming your line 2 is the one with "<

RE: [PHP] Re: unexpected T_SL

2002-09-02 Thread Todd Pasley

Hiya,

There are two reasons that I can pick up that you may be experiencing this
area:
1) You are not using PHP4 or later
2) you are using windoze and.

"Probably the nastiest gotcha is that there may also not be a carriage
return (\r) at the end of the line, only a form feed, AKA newline (\n).
Since Microsoft Windows uses the sequence \r\n as a line terminator, your
heredoc may not work if you write your script in a Windows editor. However,
most programming editors provide a way to save your files with a UNIX line
terminator."
(http://www.php.net/manual/sv/printwn/language.types.string.php#language.typ
es.string.syntax.heredoc)

It doesnt matter whether you use EOD or EOT or any other (naming convention
compliant) identifier.

I hope this helps,

Todd.

> -Original Message-
> From: Voisine [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, 3 September 2002 3:10 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Re: unexpected T_SL
>
>
> Your lucky :) because I'm using the same version and I have this
> parse error.
>
> Erwin wrote:
>
> > Voisine wrote:
> > > Hi,
> > >
> > > What is wrong witht his code? Parse error: parse error, unexpected
> > > T_SL in c:\program files\easyphp\www\tutorial\eod.php on line 2
> > >
> > >  > > $str = << > > Example of string
> > > spanning multiple lines
> > > using heredoc syntax.
> > > EOD;
> > > ?>
> >
> > To be honest, there is nothing wrong. It works in version 4.2.2
> (at least,
> > here it does) ;-))
> >
> > Grtz Erwin
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Re: unexpected T_SL

2002-09-02 Thread Steel

Hi Erwin,

Monday, September 2, 2002, 11:28:09 AM, I've got:

E> Voisine wrote:
>> Hi,
>>
>> What is wrong witht his code? Parse error: parse error, unexpected
>> T_SL in c:\program files\easyphp\www\tutorial\eod.php on line 2
>>
>> > $str = <<> Example of string
>> spanning multiple lines
>> using heredoc syntax.
>> EOD;
>> ?>

E> To be honest, there is nothing wrong. It works in version 4.2.2 (at least,
E> here it does) ;-))

E> Grtz Erwin

Why not to try
 End Of Data, and EOT -> End Of Text

Silly, but why not to try? :)

-- 
The Same,
 Steelmailto:[EMAIL PROTECTED]
   http://www.none.ru


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php