RE: [PHP] PHP and HTML

From: Date: Wed, 28 Jun 2000 15:53:23 +0000
Subject: RE: [PHP] PHP and HTML
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-3585@lists.php.net to get a copy of this message
I think the primary question that results from that is: What is the break even point between more opening/closing PHP tags, and the overhead supplied by using echo statements and less opening/closing PHP tags. At what point is one more beneficial than the other? Has anyone ever done any solid analysis on this? I would be interested in the results. Sam Masiello System Analyst Chek.Com (716) 853-1362 x289 smasiello@chekinc.com -----Original Message----- From: Andy Woolley [mailto:andy@milonic.com] Sent: Wednesday, June 28, 2000 11:46 AM To: Sam Masiello; Steven Reed; php-general@lists.php.net Subject: Re: [PHP] PHP and HTML There will always be a slight overhead with echo. best to use as few opening/closing PHP tags as possible. Bunch all HTML together and try to do as much PHP as you can in one go, this applies to ASP code as well. There are of course no hard and fast rules but it just depends on what you are trying to achive. Sometimes you can't help mixing and matching but dont use echo just because it's there. Good code comes from a little brain power so designing when and where to use PHP to output HTML should have some thought. Andy. ----- Original Message ----- From: "Sam Masiello" <smasiello@chekinc.com> To: "Steven Reed" <steven@domino.com>; <php-general@lists.php.net> Sent: Wednesday, June 28, 2000 4:39 PM Subject: RE: [PHP] PHP and HTML > > I think this is more of a personal preference issue than anything else. > Personally I prefer not using echo statements to output regular HTML, if > anything because I think it is easier to read that way.....there might be a > performance issue with this question as well, but I do not know that for > sure. > > Sam Masiello > System Analyst > Chek.Com > (716) 853-1362 x289 > smasiello@chekinc.com > > -----Original Message----- > From: Steven Reed [mailto:steven@domino.com] > Sent: Wednesday, June 28, 2000 11:37 AM > To: php-general@lists.php.net > Subject: [PHP] PHP and HTML > > Hello All, > > I am new to PHP, i was wondering which method is best for displaying HTML on > PHP pages, efficiently. > Is it to embed the HTML statements inside of Echo statements, or to close > the PHP tags and then have normal HTML ? > > Thanks in advance - Steven. > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#3585) next »