First search request/response that works.
[egate.git] / www / search.egw
1 <html>
2 {
3 # $Id: search.egw,v 1.2 1995/10/27 17:30:16 adam Exp $
4
5 proc search-response {} {
6     global sessionWait
7     set sessionWait 0
8
9     htmlr "search response <br>"
10     set r [z39.1 resultCount]
11     htmlr "<strong>$r hits</strong><br>"
12     htmlr "</body></html>"
13 }
14
15 proc fail-response {} {
16     global sessionWait
17     set sessionWait 0
18
19     htmlr "<strong>failed</strong><br>"
20     htmlr "</body></html>"
21 }
22
23     global sessionWait
24
25     z39 callback search-response
26     z39 failback fail-response
27     set sessionWait 1
28     ir-set z39.1 z39
29     z39.1 databaseNames [form base]
30     z39.1 search [form entry1]
31     htmlr <head>
32     htmlr "<title> WWW/Z39.50 Gateway Search Result ...</title>"
33 }
34 </head>
35 <body>
36 sessionId: {html $sessionId} <br>
37 sessionParms: {html $sessionParms} <br>
38 form: {html [form]} <br>
39 target: {html $t} <br>
40 databases: {html $databases} <br>
41 <h2> Search in databases </h2>
42 {
43     htmlr [form entry1] <br>
44 }