Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

DevArticles:
Sticking with Static (HTML)
Apr 11, 2003 @ 12:01:41

One thing that can dramatically increase the livelyhood of your site (if you do a lot of database queries), is caching some static HTML for your pages. Think about it - wouldn't it be nice to, at a moment's motice, switch over to a static version of a page when lots of people suddenly decide it's important? Well, here to help is DevArticles.

In one of their latest, Static HTML Generation With PHP, they show you how to use a cron job on a unix machine to query your site, and make a "static backup" of everything on the site. It goes out, grabs the page that you specify, and then makes a local static copy of it. Using a script like this can help to not only make your site more stable, but can also help more people get to see what you want them to - which is what it's all about.

The only thing this script doesn't do that it should (to make life easier) is try to follow links on a page. Then you could just point it at a site and let it rip...of course, then you might as well just use wget.

tagged:

Link:


Trending Topics: