28/10/05

Whipping those Grots

Permalink 11:31:55 pm, Categories: Programming, 236 words  

Or "How I Got Speed Increases In My CMS"

I've just updated the Skins@HWT CMS (known as Grots) with some speed increases that I've been working on. Although timings can still be variable (due to other things running on the server) the front page generation time is now down from averaging between 0.0075 and 0.0085 to averaging between 0.0065 and 0.0075. This doesn't sound like much, but in reality it's one thousandth of a second on a load time of around eight thousandths of a second - so it's about an eighth!

The main improvement is to use static files for the HTML skinning functions and language strings instead of pulling them out of the database each time. I can now generate the static files through my admin control panel (as long as I manually temporarily set the permissions on the parent folder to 777 when I first create the files!). I've also made some minor tweaks to stop it performing excessive checks such as strpos() in some situations, caching the result instead.

One very useful feature that I found for the skinning (since they are functions of a class) is that PHP classes can actually be "extended" like real object-oriented classes. All this time I've been using PHP4 classes, and I just thought that they were ways of grouping functions and variables while not being fully object orientated!

Now, I wonder if I can squeeze any more out of it...

Comments, Trackbacks:

No Comments/Trackbacks for this post.

Navigation