Skip to main content.
home | support | download

Back to List Archive

Re: Including meta tags in field and default keyword search

From: Bill Moseley <moseley(at)>
Date: Tue Sep 28 2004 - 13:52:09 GMT
On Mon, Sep 27, 2004 at 11:03:45PM -0700, wrote:
> I'm trying to get data in a meta tag to be searchable as part of a
> default query and as part of a field query. However, the moment
> I define the meta tag, using MetaNames, it no longer appears in
> the default search. e.g.

The secret about swish is there is no "default" search -- only
specific meta tag searches.  Think of them as columns in a database.
If you want to search multiple columns in a database you either have
to specify both columns or place your data in more than one column.

So, to have things searchable in more than one metaname you have two

1) like you said, you can search both at the same time:

     swishdefault=(Australian) or booktitle=(Australian)

but that's two lookups in the index.

2) Or you can nest your data:

In XML you would do:

                Australian Employment Law Guide

                During a period of stand-down

            Give the employee all you can afford.

And then use: 

    metanames all booktitle keywords

Of course, you are making your index slightly larger in that case.
(BTW -- 

The swish parser will actually allow you to use fake HTML tags as
metanames -- so in broken HTML you can do this:

        <title>Payment while stood down</title>
            Give the employee all you can afford.

                Australian Employment Law Guide

                During a period of stand-down

and with this you would use:

    MetaNameAlias swishdefault body
    metanames booktitle keywords

or maybe

    metanames body booktitle keywords

Of course, you probably don't find those a very good format for your
web pages.  If you content is in a database then the XML layout might
be best.  Otherwise, you will likely have to pre-parse your HTML files
and reformat while indexing.

> BTW... does MetaNamesRank work in any version of Swish?

To some small degree.

Bill Moseley

Unsubscribe from or help with the swish-e list:

Help with Swish-e:
Received on Tue Sep 28 06:52:29 2004