Re: eof bof in php

From: Date: Tue, 23 Dec 2008 15:13:20 +0000
Subject: Re: eof bof in php
References: 1 2 3 4 5 6 7 8 9 10 11  Groups: php.general 
Request: Send a blank email to php-general+get-285006@lists.php.net to get a copy of this message
At 2:21 PM -0500 12/22/08, Anthony Gentile wrote:
I would argue it is better practice as: <h1><?php echo 'Hello World'; ?></h1> than <?php echo "<h1>Hello World</h1>"; ?> Anthony Gentile
Certainly, but all you have done here is to move your <?php ?> to different places. There is a threshold one reaches in deciding where is the "best" place to put the "<?php ... ?>" -- it's a personal choice. With me, a one liner is sufficient for me to use: <h1><?php echo 'Hello World'; ?></h1> For more than that, I usually: ?> html <?php I use heredoc for email text, but not for html. I do this primarily because I like the way my editor works for showing paired tags and braces. It makes it easy for me to check tag pairing. Cheers, tedd -- ------- http://sperling.com http://ancientstones.com http://earthstones.com

« previous php.general (#285006) next »