"whereas to echo it you'd have to concatenate the string." false
you don't have to concat strings with echo you can print vars the same way as print
regards
16/07/01 17:48:43, "Steve Brett" <[EMAIL PROTECTED]> wrote:
>i seem to remember reading somewhere that print acts like (is) a function,
>p
I don't know what to say, my comment was based on
http://www.faqts.com/knowledge_base/view.phtml/aid/1/fid/40
note the author.
I ran your code in both windows and linux and got
faster speeds, on a regular basis, for echo. That
said, the speed differences were not great(minor is a
good descript
> As I understand it, echo is not a function it's a
> language something or other, supposedly it runs
> slightly faster than print given the same output.
time_start = $this->GetMicroTime();
}
function Stop(){
$time_end = $this->GetMicroTime();
$this->time_delta
echo and print both work.
> -Original Message-
> From: Steve Brett [mailto:[EMAIL PROTECTED]]
> Sent: Monday, July 16, 2001 11:49 AM
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] echo vs printf
>
>
> i seem to remember reading somewhere that print acts like
Actually, you can do the same thing with echo.
echo "you have $points points";
As I understand it, echo is not a function it's a
language something or other, supposedly it runs
slightly faster than print given the same output.
however, given it's Monday, I could be wrong.
rm
>
> also you can
i seem to remember reading somewhere that print acts like (is) a function,
presumably returning false if it cannot print to screen, whereas echo just
dumps it.
also you can drop vars in print like
print "you have $points points";
whereas to echo it you'd have to concatenate the string.
Steve
On 16-Jul-01 brother wrote:
> Why should I use printf instead of echo and vice versa?
>
printf print-formated
$a=12.3456;
echo $a, '';
printf('%1.2f', $a);
12.3456
12.34
> As for today I use printf mostly but I don't know why.
You prolly mean print; There may be some minor differences fro
Why should I use printf instead of echo and vice versa?
As for today I use printf mostly but I don't know why.
brother
Mail: [EMAIL PROTECTED]
UIN: 4722160
Web: http://motd.st
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands,
8 matches
Mail list logo