Posted by Benjamin on 10/11/06 01:49
ob stands for output buffer. What this does is keep all the data you
print out in a buffer until the end of the script. There, the HTTP
headers are sent first then the body (this is normal). What normal
output (just ob_start()) buffering allows you to do is send headers
even if you've printed out some data. When you pass a parameter to
ob_start PHP sends the data to the output handler you specified in the
parameter. ob_gzhandler compresses the output so it takes up less space
and takes less to travel to the clients browser.
GKF Joe wrote:
> I have recently heard about " ob_start('ob_gzhandler'); "
> but I don't really know how to use it. Should it be a part of every
> *.php file? Does it need to be "turned off"? I've looked at the manual,
> but that only confused me. Can someone please tell me what I need to
> know (which might not even be what I asked).
Navigation:
[Reply to this message]
|