Geoff:
I've tried the query from the command line and it works PERFECTLY! But now
on PHP, I'm getting this error:
Unable to read word database file
'/home/sites/site21/local/htdig/db/db.words.db'Did you run htmerge?
But my databases are in ../local/htdig/db/roguespear.
What I'm guessing is that my query that specifies the config file is not
being properly sent to the htsearch program.
Here's my PHP code - as you can see I've done away with PHP variable and
used the EXACT same query I used on the command line:
$words = EscapeShellCmd(UrlEncode($search));
$config = EscapeShellCmd(UrlEncode("roguespear"));
$format = EscapeShellCmd(UrlEncode("roguespear"));
$query = "config=$config&format=$format&words=$words";
$command="/home/sites/site21/local/htdig/bin/htsearch \"$query\"";
echo $command;
exec("/home/sites/site21/local/htdig/bin/htsearch
\"config=roguespear&format=roguespear&words=nato\"",$result);
That will print out the error specified above.
Reason I'm not using a wrapper script is because it gives me an error as
well - and I've had more luck with this method. The error when I use a
wrapper script comes up in my /etc/httpd/logs/error error log. And that
error is:
: not a legal variable name
: No such file or directorydig/htdig.sh: /home/sites/site21/local/htdig/bin
I'm dying for more suggestions - this is going beyond frusteration for me.
Thanks in advance,
- Mike
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of Geoff
Hutchison
Sent: Saturday, July 14, 2001 10:03 AM
To: Michael "NightEye" Aeberhard
Cc: [EMAIL PROTECTED]
Subject: Re: [htdig] Always getting "No Matches"
At 11:21 AM -0400 7/13/01, Michael \"NightEye\" Aeberhard wrote:
>But now, whenever I do a search, I always get the NO MATCHES error in my
>$result in PHP.
Have you checked to make sure the words field is being set correctly?
Just make sure the query is printed out somewhere. And if you run
htsearch from the command-line with that query, do you get the
results you expect?
>template_map: roguespear roguespear
>/home/sites/site21/web/_search/results-template.html
You probably also want to set the template_name attribute:
<http://www.htdig.org/attrs.html#template_name>
--
--
-Geoff Hutchison
Williams Students Online
http://wso.williams.edu/
_______________________________________________
htdig-general mailing list <[EMAIL PROTECTED]>
To unsubscribe, send a message to
<[EMAIL PROTECTED]> with a subject of unsubscribe
FAQ: http://htdig.sourceforge.net/FAQ.html
_______________________________________________
htdig-general mailing list <[EMAIL PROTECTED]>
To unsubscribe, send a message to <[EMAIL PROTECTED]> with a
subject of unsubscribe
FAQ: http://htdig.sourceforge.net/FAQ.html
RE: [htdig] Always getting "No Matches"
Michael \"NightEye\" Aeberhard Mon, 16 Jul 2001 12:30:03 -0700
- [htdig] Always getting "No M... Michael \"NightEye\" Aeberhard
- Re: [htdig] Always getting &... Geoff Hutchison
- Re: [htdig] Always getting &... Michael \"NightEye\" Aeberhard
- Re: [htdig] Always getti... Gilles Detillieux
- RE: [htdig] Always getting &... David Patterson

