Empty Buffer early if your page is in php

When users request a page, it can take 200 to 500 milliseconds for the server to create the html code.

During this time, the browser is inactive as it awaits the arrival of the data. In PHP you have the flush () function. The one that allows you to send a partially ready HTML response to the browser so the browser can start looking for the components while in the background it is busy with the rest of the HTML page. The benefit is mainly found in busy backgrounds or light covers.

A good place to consider this is immediately after the header, it is generally easier to produce and allows you to include any CSS or Javascript file so that the browser starts searching in parallel while it is still processing in the background.


… ! - css, js -


? php flush (); ?


… ! - content -

Date update on 2020-11-13. Date published on 2020-11-13. Category: Computer class Author: Oscar olg Fuente: tecnologia