« August 2006 | Main | February 2007 »
September 16, 2006
Searching a single blog - Update
I have a new fix for the broken search form on the search results page problem I discussed yesterday, one that does not involve everyone editing their templates.
So relax, life is good, and you can ignore my previous message.
Posted by elf123 at 03:14 PM Topic(s):
September 15, 2006
Searching a single blog
There is a problem in the way that Movable Type searches individual blogs.
The problem is that if you do a search, and then search again using the search form you find on the results screen, Movable Type loses track of which blog you were in, and ends up searching the entire site.
To fix this, I created a new Movable Type search template that only searches one blog.
Update: Please ignore the following directions. Rather than reconfiguring every blog to use a custom search template, I've changed the default search template so that it only searches one blog.
To use this template, you need to add an extra field to your search form to tell MT to use the 'oneblog' template.
By default, you'll find search forms on the Main Index and Master Archive Index templates for each blog. Edit each of these templates and add a hidden 'Template' field to each search form.
Here's an example:
<form method="get" action="<$MTCGIPath$><$MTSearchScript$>"> <input type="hidden" name="IncludeBlogs" value="<$MTBlogID$>" /> <input type="hidden" name="Template" value="oneblog" /> <input id="search" name="search" size="20" class="blog_search_text" /> <input type="submit" value="Go" class="blog_search_text" /> </form>
Posted by elf123 at 11:03 AM Topic(s):