Wow, I was pleasantly surprised with the rush of positive feedback from today's Google API hack for Movable Type users. A number of people asked for some new features, and given that it was only anoither 7 lines of perl code or so, I coded it up!The new patch to MT 2.11 adds the following new features to the MTGoogleSearch tag. It adds the following new properties that will change the behavior of the tag:
- title="1" : This will cause the google search query to be the title (MTEntryTitle) of your current blog entry
- excerpt="1" : This will cause the google serch query to be the entry excerpt (MTEntryExcerpt) of the current blog entry
Those two properties are mutually exclusive (along with the current query="" and related="1" properties). In addition, if you use strip_html="1" inside the MTGoogleSearch tag, it will remove any html that Google replies with, including <b> tags that surround the search query terms. This is a patch on the default build of Movable Type 2.11. If you've already installed my previous patch, it might be easier to just back out the patch and install this one. By the way, I haven't done a lot of testing with the MTEntries query code (entries="1") so if you do use it, please send me feedback.