Please Log in to join the conversation.
Please Log in to join the conversation.
The second issue is that in PHP 4, echoing multiple times is slower than storing everything in a string and echoing it in one call. This is because echo is an expensive operation that could involve sending TCP/IP packets to a HTTP client. Of course accumulating the string in $s has some scalability issues as it will use up more memory, so you can see a trade-off is involved here.
Please Log in to join the conversation.
Please Log in to join the conversation.
Please Log in to join the conversation.