Subject: [htdig] passing a string through to htsearch results
From: Malcolm Austen (email@example.com)
Date: Thu Aug 31 2000 - 01:42:42 PDT
I have a working solution, but it will make one or two people cringe 8-)
I can't see a better solution (at least not without delving into areas
like parsing the search results before delivering them to the user) but,
of course, I may have missed something that's blindingly obvious to
everyone else! I can see what I want, so if there isn't a better solution
currently (using 3.1.5 on Red Hat Linux) then this will become a request
for a (modest?) enhancement.
I have a script that takes a simple code and generates a search form so
that, for example, http://wwwsearch.ox.ac.uk/cgi-bin/oxunit?oucs will
generate a search form in which the query code has been used to deliver a
header and to create a hidden "restrict" input field.
The "restrict" field gets passed through to the search results without any
problem but I need to pass through the header string so it can be
substituted in the results header.html file.
The (horrid) solution:
Having found no other means of doing this, I concluded that I could use
the "exclude" field for the purpose. I'm not using "exclude" anywhere
(yet?) for its real purpose and by including HTML markup in the string I
can ensure it won't ever match to a URL and exclude anything. Of course,
there is at least a theoretical performance hit 8-(
This is working now (despite the paragraph of the search form that says it
isn't) but I don't want to "go public" here with this facility without
some sight of a better solution in the longer term.
The possible enhancement for 3.2:
I only need to pass one string through but someone will want more! Could
we have, say, USER_STRING_<digit> as a hidden input field option to be
passed through into search results just like restrict and exclude and
available for substitution as $(USER_STRING_n)
| Malcolm Austen, Tel: +44(0) 1865 273216
| Oxford University Computing Services, Fax: +44(0) 1865 273275
| 13 Banbury Road, Email - firstname.lastname@example.org
| Oxford, OX2 6NN, England WWW - http://users.ox.ac.uk/~malcolm/
To unsubscribe from the htdig mailing list, send a message to
You will receive a message to confirm this.
List archives: <http://www.htdig.org/mail/menu.html>
This archive was generated by hypermail 2b28 : Thu Aug 31 2000 - 01:44:00 PDT