Re: Bug #15030 Updated: echo concatenates strings and string function call in bad order
| From: | Markus Fischer | Date: | Mon, 14 Jan 2002 22:51:56 +0000 |
| Subject: | Re: Bug #15030 Updated: echo concatenates strings and string function call in bad order | ||
| References: | 1 2 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-77073@lists.php.net to get a copy of this message | ||
On Mon, Jan 14, 2002 at 07:25:18PM -0000, hholzgra@php.net wrote :
> ID: 15030
> Updated by: hholzgra
> Reported By: ivosh@winet.cz
> Status: Bogus
> Bug Type: Output Control
> Operating System: Debian Linux
> PHP Version: 4.0.6
> New Comment:
>
> just a short explaination: echo contatenates nothing,
> it *immediately* generates the requested output
> plus arguments are evaluated before they are passed
> to a function (lets assume "echo" is a function for
> now)
>
> so before "echo" is called the argument string is
> evaluated, for this Translate() is called, which
> itself contains an echo call which is executed first now
>
> what you wand is "return $R;" instead of "echo $R;"
> in Translate()
That's the most confusing explaination I've ever read :)
--
Please always Cc to me when replying to me on the lists.