I can search fine from the command line, but when I go to search using
swish.cgi (or any other .cgi/.pl script), I get 0 results. (no errors,
and everything compiles, just no results). I checked the archives and no
one with this problem had a reply posted.
Here's my .swishcgi.conf that I use with swish.cgi:
return {
swish_binary => '/Program Files/SWISH-E',
swish_index => '/Data/webroot/cgi-bin/index.swish-e',
title => 'Search Intranet',
};
And for a different .cgi file:
# Absolute path and command to execute the Swish searcher
$swish = "/Program Files/SWISH-E/swish-e"; #I've tried a number of
things on this line. The current format is how I search at the command
prompt from the directory where my index is: "\program
files\swish-e\swish-e" -w somequery
# URL of where you put this cgi
$swishcgi = "http://someurl.org/cgi-bin/egads.pl";
# Optional parameters to pass to the Swish searcher
$params = " ";
# Absolute path and filename of your created Swish index file
$index1 = "/Path/to/cgi-bin/index.swish-e";
#Here's where it supposedly searches.
$count = 0;
open(SWISH, "$swish -w $query -f index1"); # -m $results $search_tags -f
$index1|");
while (<SWISH>)
{
# First, check to see if search produced an error
chop;
if ($_ eq "err: no results")
{&search_error("<CENTER><FONT COLOR=RED SIZE=5><B>There were no items
that matched your search request.</B></FONT></CENTER>");}
if ($_ eq "err: could not open index file.</B></FONT>")
{&search_error("<CENTER><FONT COLOR=RED SIZE=5><B>Could not open Index
File $index1.</B></FONT></CENTER>");}
if ($_ eq "err: no search words specified")
{&search_error("<CENTER><FONT COLOR=RED SIZE=5><B>Please Enter at least
one Search Word.</B></FONT></CENTER>");}
if ($_ eq "err: a word is too common") {&search_error("<CENTER><FONT
COLOR=RED SIZE=5><B>One of your search terms is too common, please try
again.</B></FONT></CENTER>");}
# Next Line ignores lines that begin with a non-digit
next if /^\D/;
$count++;
push(@results, $_);
}
Sarah
Received on Mon Oct 18 10:44:35 2004