Document how to create a TPAC/KPAC search box
authorDan Scott <dscott@laurentian.ca>
Fri, 24 Aug 2012 01:12:40 +0000 (21:12 -0400)
committerDan Scott <dscott@laurentian.ca>
Fri, 24 Aug 2012 01:19:41 +0000 (21:19 -0400)
Now that we're in the land of the TPAC, it's time to ensure that
everyone can update their simple search boxes so that they no longer
point at the JSPAC and point at the TPAC or Kid's OPAC instead.

Signed-off-by: Dan Scott <dscott@laurentian.ca>

docs/opac/search_form.txt [new file with mode: 0644]
docs/root.txt

diff --git a/docs/opac/search_form.txt b/docs/opac/search_form.txt
new file mode 100644 (file)
index 0000000..182c494
--- /dev/null
@@ -0,0 +1,28 @@
+Adding an Evergreen search form to a web page
+=============================================
+
+To enable users to quickly search your Evergreen catalog, you can add a
+simple search form to any HTML page. The following code demonstrates
+how to create a quick search box suitable for the header of your web
+site:
+
+.Sample search form
+[source,html]
+------------------------------------------------------------------------------
+<form action="http://example.com/eg/opac/results" method="get">    <!-- <1> -->
+    <input type="search" alt="Catalog Search" maxlength="200"
+            size="20" name="query"
+            placeholder="Search catalog for..." />
+    <input type="hidden" name="qtype" value="keyword" />           <!-- <2> -->
+    <input type="hidden" name="locg" value="4" />                  <!-- <3> -->
+    <input type="submit" value="Search" />
+</form>
+------------------------------------------------------------------------------
+<1> Replace ''example.com'' with the hostname for your catalog. To link to
+    the Kid's OPAC instead of the TPAC, replace ''opac'' with ''tpac''.
+<2> Replace ''keyword'' with ''title'', ''author'', ''subject'', or ''series''
+    if you want to provide more specific searches. You can even specify
+    ''identifier|isbn'' for an ISBN search.
+<3> Replace ''4'' with the ID number of the organizational unit at which you
+    wish to anchor your search. This is the value of the ''locg'' parameter in
+    your normal search.
index a892b23..caf366f 100644 (file)
@@ -302,6 +302,15 @@ include::opac/my_lists.txt[]
 
 include::opac/kids_opac.txt[]
 
+// Push titles down one level.
+:leveloffset: 1
+
+include::opac/search_form.txt[]
+
+// Return to normal title levels.
+:leveloffset: 0
+
+
 Developer Resources
 ===================