Skip to main content.
home | support | download

Back to List Archive

Re: site:mydomain.com

From: Bill Moseley <moseley(at)not-real.hank.org>
Date: Tue Dec 19 2006 - 21:09:17 GMT
On Tue, Dec 19, 2006 at 12:54:38PM -0800, James wrote:
> RE: This is an example of limiting by site: http://search.apache.org/
> 
> I am not clear what is the example.  Perhaps you could perform a search and
> copy one of the result links to the list discussion so that I can click on
> it and see what you mean.

It's an example of searching multiple sites.

It uses this in the swish config file:

    ExtractPath site regex "!^http://httpd.apache.org/docs/.*$!httpd docs1!"
    ExtractPath site regex "!^http://httpd.apache.org/docs-2.*$!httpd docs2!"
    ExtractPath site regex "!^http:/([^.]+).+$!$1!"


The .swishcgi.conf file contains this to make use of that extracted
host name:

    my @sites = qw/httpd docs1 docs2 java www apr james/;

    [...]

    select_by_meta  => {
            method      => 'checkbox_group',
            columns     => 3,
            metaname    => 'site',
            values      => \@sites,
            labels      => \%labels,
            description => 'Limit search to: ',
        },

that select_by_meta is an option of swish.cgi -- and is somewhat
explained in the config section of the script.

    http://swishe.cvs.sourceforge.net/swishe/swish-e/example/swish.cgi.in?revision=1.22&view=markup

But, that's just one way to do it -- I would frankly write my own user
interface and not use that script (I'd rather use a script that was
customized for my needs.)


> I was reading
> http://swish-e.org/docs/swish-config.html#document_contents_directives and
> trying to make sense of it in light of my question / this issue.  Could you
> or Peter point me to the documentation more explicitly?

    http://swish-e.org/docs/swish-config.html#extractpath

That just applies a regex to the document's "path" and the captured
part is placed in a metaname for that document.







-- 
Bill Moseley
moseley@hank.org

Unsubscribe from or help with the swish-e list: 
   http://swish-e.org/Discussion/

Help with Swish-e:
   http://swish-e.org/current/docs
   swish-e@sunsite.berkeley.edu
Received on Tue Dec 19 13:09:19 2006