|
calling findinsite-js
GREAT! You are now ready to link to findinsite-js from your web site.
Search page link
Your first option is simply to provide a link direct to findinsite-js.
It is probably best not to use an absolute URL.
As described in the findinsite-js Installation Guide,
the actual URL you must use to display the findinsite-js search page will vary.
Here are a couple of possible URLs:
When you provide this link, you might call it
Advanced search.
Search box
It is straightforward to add a search box to a web page...
but see the charsets information below.
In most cases, the following HTML will work:
<form method="get" action="/findinsitejs/search">
Search for: <input name="Text" type="text" size="20" maxlength="80" />
<input type="submit" value="Search" />
</form>
You might need to change the URL used for the FORM ACTION attribute value.
If you want your search box to take up a small amount of space, try this HTML:
<form method="get" action="/findinsitejs/search" style="display:inline;">
<input name="Text" type="text" size="20" maxlength="80" />
<input type="submit" value="Search" />
</form>
Search box Character Set
If you use a search box, then you need to think about the character set (charset)
of the page the box is in.
If the page is in character set "ISO-8859-1" then the above forms will be OK.
However if the page is in a different charset, then the browser will return
any characters using that charset. Unless you tell findinsite-js otherwise,
findinsite-js will interpret these characters as "ISO-8859-1" and therefore might
search for the wrong text. To fix this, tell findinsite-js the charset of the page using
the cs runtime parameter.
For example, if the page is in the Japanese "shift_jis" charset, then set
cs by adding this code into your form:
<input name="cs" type="hidden" value="shift_jis" />
The findinsite-js localised search pages always use the "UTF-8" charset which is able to represent
all possible characters, while being recognised by virtually all recent browsers.
Subset searches
If findinsite-js is searching more than one search database, you can provide the user with a check box
list of available subsets.
See the Subsets page for details of how to set this up.
|