According to [EMAIL PROTECTED]:
>Thanks for your response Torsten, I can cope with the PHP bit
>which would dynamically decide which index to use, but it's the
>htdig part. Would I use a different config file, or something like
>that, because I don't see anywhere to put a reference to the index
>that is created. In fact I don't even know where it is stored!!
Directories can be specified at compile time and (although limited)
at run-time through the configuration file of ht://Dig.
Have a look at
http://www.htdig.org/hts_general.html
http://www.htdig.org/hts_form.html
http://www.htdig.org/cf_variables.html
The configuration file specifies what database to use for answering
the query. Since most of the configuration file should be identical
for both of your setups, I'd suggest you use the "include" directive
for the common part of the configuration. Each configuration file is
then placed in the configuration directory (specified at compile-time).
In the search form, you need to set the "config" parameter to the value
of the basename of the configuration file to use (i.e. no directory or
file extension).
So the form for the first query should look something like
<INPUT TYPE="hidden"
NAME="config"
VALUE="<?php echo(GoodIp()?"inside":"outside"); ?>">
with PHP, where GoodIP() is a function returning a boolean value
depending on the origin of the requesting client, "inside" is the
name of the configuration file for your staff members and "outside"
is the configuration file for the public community, both of which
are placed ind the configuration dircetory of ht://Dig (with the
file extension ".conf").
As stated above, the common part of these configuration files can
be "include"d whereas the unique part specifies the database and
the result templates to be used (which need not being written in
server-parsed HTML unless you require a wrapper for some postpro-
cessing).
hth,
Torsten
--
InWise - Wirtschaftlich-Wissenschaftlicher Internet Service GmbH
Waldhofstra�e 14 Tel: +49-4101-403605
D-25474 Ellerbek Fax: +49-4101-403606
E-Mail: [EMAIL PROTECTED] Internet: http://www.inwise.de
------------------------------------
To unsubscribe from the htdig mailing list, send a message to
[EMAIL PROTECTED] containing the single word unsubscribe in
the SUBJECT of the message.