I am outputting data on my website from a database. It works fine, except when the page loads, it will start displaying in different spots and parts of the page will load at different times making the page jump around until it loads. I want it to load at the same time like most sites(Facebook, twitter, etc) and not output parts of code at different times. I am using PHP and I have no idea what is causing this. Anyone know what is happening or had any of the same problems with this?
Share
You could try output buffering:
This will capture all output generated to a buffer, and dump it when the script has completed. However, this means that no content will be sent until your queries have completed. Perhaps another consideration you should make is optimizing your database queries as best as possible, to reduce the bottleneck impact of database hits.