Fast Search

One of the things my web host, Dataflame, likes to do every so often is to lock down some of the files in this blog, claiming they're using too many resources. Dataflame's staff never bother to tell my they've done this so I never know exactly how long my site's been crippled for. But I always find out.

I've done several things over the years to reduce resource loads: I've converted various templates to dynamic publishing to reduce loads at page rebuild time; I've switched to using Fast CGI instead of CGI. My latest trick, since the file locked down was mt-search.fcgi, was to use FastSearch 2.0.

I have to say I'm extremely pleased with the results.

I've been eyeing FastSearch for a while now, since among its useful attributes is its ability to include PHP in search templates. Movable Type's search page is a CGI script so I've been using various workarounds, such as <MTInclude file="…"> and new index templates, to include PHP content on search and tag listing pages. However, simple pagination has been impossible.

This all changes with FastSearch. Not only does FastSearch reduce resource use when searching, it includes built-in pagination functions. It also permits Google-style highlighting of search results:

Pagination

I've had to lose case-sensitive and regular expression searches, but I'm not too bothered by that. I also had to pony up a $10 donation to get the relevant modifications to permit URL-cleaning for tags (ie so that a URL of the form ../tag/xxx gets mapped to the search page with tag=xxx as a variable parameter. On the plus side again, FastSearch also modifies the <MTTagSearchLink> tag to include a directory attribute that lets you specify the directory of such cleaned up tags. Nice.

All in all, well worth the investment and pretty simple to work with, once you've got the hang of it.

Leave a comment

Recent Entries

  • MT 4.1 now out

    Movable Type 4.1 is now available, I notice. I gave it a try today and while there are obvious improvements everywhere, there are a couple...

  • MT4: Finally made it

    Finally. I've done it. I've made the switch. With the slight exception of MT Blogroll, which I can do without for now (but which...

  • MT4: nearly there

    Tried again with my bi-weekly MT4 upgrade attempt. We're nearly there now, I reckon. Simply Threaded was giving me some problems and not showing...

  • MT-MyBlogLog

    I've been trying to 'Voxify' my media blog of late. That's included comment threading, relative dates, changes to stylesheets, etc. But the biggest change...

  • MT4: not yet

    The observant will have noticed that I've still not migrated my blogs over to MT4. I did have an abortive attempt at it last...

Close