Re: Print or Echo takes lots of time
| From: | Colin Guthrie | Date: | Tue, 26 Sep 2006 09:08:25 +0000 |
| Subject: | Re: Print or Echo takes lots of time | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-242216@lists.php.net to get a copy of this message | ||
Google Kreme wrote:
> On 25 Sep 2006, at 06:11 , Sancar Saran wrote:
>> $strPage = "<html> yada dayda";
>> ...
>> $strPage.= " another html tags";
>> ...
>> $strPage.= getSqlDataAndCreateSomeHtmlCOde();
>
> If this is generating hundred of K of HTML, use ' instead of "
>
> (yes, it's faster).
In this example tho', it is not the string processing that is taking up
the time. The $ expansion etc. will be done when building the string
$strPage, not at the echo stage which is where the OP is seeing the delay.
Col.