Execute a shell-script to search

Nathan Torkington (Nathan.Torkington@vuw.ac.nz)
Wed, 21 Jul 1993 11:44:08 +1200


Stephen C. Pope writes:

> OK, here's (IMHO) a better way to do this.
> [...]

Very sexy :) What (ideally) I'd like to do is to be able to specify,
in /etc/httpd.conf is
SEARCH file:/home.html /usr/local/bin/www/search-home-page
SEARCH file:/*.html /usr/local/bin/www/search-this-page

Specify what the search program is for each page. Then, when it comes
time to fork and exec, the argv[0] of the search process is set to the
page that it would have been searching (/usr/local/www/home.html for
eg).

Nevertheless, I think your solution of using the extension of the
executable to specify the data returned is rather elegant. I hope
CERN are taking notes :)

Nat