note 36467 added to function.ob-get-contents

From: Date: Fri, 10 Oct 2003 15:25:08 +0000
Subject: note 36467 added to function.ob-get-contents
Groups: php.notes 
Request: Send a blank email to php-notes+get-58198@lists.php.net to get a copy of this message
On an industrial scale, the most obvious use of ob_get_content() is of course the generation of static html pages from dynamic php ones. If your website is output with php with the content taken from a DB; as the site grows, so do the hits on the database per minute, and hence the load on your server. Static page generation is a standard method of load balancing. A scheduled task / cron job can be run nightly/weekly/whenever to create the html versions of each page that doesn't need to be completely up to date for every single page view. If static html can be served 10 times a second, rather than php and an expensive database hit - load problems are clearly going to disappear. Those of you writing your own Content Management Systems will only become a market competitor if your product can do this. ob_get_content() is your friend! ---- Manual Page -- http://www.php.net/manual/en/function.ob-get-contents.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+36467 Delete -- http://master.php.net/manage/user-notes.php?action=delete+36467&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+36467&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#58198) next »