Re: speed comparison
| From: | Jeff Bluemel | Date: | Tue, 19 Nov 2002 00:14:18 +0000 |
| Subject: | Re: speed comparison | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-124998@lists.php.net to get a copy of this message | ||
depends on my situation, but I use both techniques at times...
"Justin French" <justin@indent.com.au> wrote in message
news:B9FFC6DE.1788F%justin@indent.com.au...
> I think the difference would be immeasurable, but to me, I think it would
> make sense if PHP didn't have to parse plain HTML...
>
> So IMHO,
>
> <HTML><BODY><?=$foo?>
>
> /should/ be slightly quicker than
>
> <? echo "<HTML><BODY>{$foo}"; ?>
>
> The general consensus on the list seems to be "go with whichever one you
are
> more comfortable with, is more readable, and faster to write.
>
>
> Justin
>
>
> on 19/11/02 10:39 AM, Chris Edwards (chris.edwards@obinet.com) wrote:
>
> > Which would run faster and generate less load on the server, or does it
> > matter:
> >
> > <?php
> >
> > $output = "
> > <table....
> > ...
> > ...html
> >
> > .... $name $phone ...
> > ";
> >
> > echo $output;
> > ?>
> >
> > ------ OR -------------
> >
> > <table....
> > ...
> > ...
> > <?php echo $name ?> ... <?php echo $phone ?>
> > ..
> > </table>
> >
> > I find it sucks to try and put all the php tags around stuff, so I just
> > include it all.....
> >
> > --
> > Chris Edwards
> > Web Application Developer
> > Outer Banks Internet, Inc.
> > 252-441-6698
> > chris.edwards@obinet.com
> > http://www.OuterBanksInternet.com
> >
>
> Justin French
> --------------------
> http://Indent.com.au
> Web Developent &
> Graphic Design
> --------------------
>