[nycphp-talk] Arrays and string concat in classes
Michael Haszprunar
michaelhasz at gmx.net
Mon Apr 24 12:26:31 EDT 2006
<lurk mode off>
Hi folks,
Today I found an interesting/anoying thing regarding classes in PHP4.
What I tried was this:
class blabla
{
var $bla = array(
'test' => MY_CONSTANT.'some text'
);
}
and PHP threw an error ("syntax error, unexpected '.', expecting ')'").
It seems that string concatenation is not allowed.
Is this a bug or a feature? Why should this not be allowed?
Thanks and also many thanks for all the other interessting things I can
read on that mailing list.
Kind regards from Munich, Germany
Michael
</lurk mode on>
More information about the talk
mailing list