Re: Quotation marks considered harmful

From: Date: Fri, 05 May 2006 13:29:23 +0000
Subject: Re: Quotation marks considered harmful
References: 1 2 3 4  Groups: php.general 
Request: Send a blank email to php-general+get-235634@lists.php.net to get a copy of this message
On 5/4/06, John Hicks <johnlist@gulfbridge.net> wrote:
Why not develop a language syntax that has distinct open and close string delimiters?
I consider HEREDOC to be the answer to that kind of prayer. For quick one-liners I find it overkill, but I felt so freed when I discovered it for creating large string blocks, like HTML templates with PHP intermixed. The only thing I wish HEREDOC could do is evaluate functions within the string blocks. But at least it will evaluate object methods, so if you're a staunch OOPer, you're set. (Yet another reason why I'm a convert) All other comments about having to escape alternative delimiters are valid. -John W

« previous php.general (#235634) next »