A lot of work on scan. Tables used to display scan terms and hits.
[egate.git] / www / targets.egw
1 <html>
2 {
3 # $Id: targets.egw,v 1.18 1996/01/26 15:50:10 adam Exp $
4     source ztargets.conf
5     if {[info commands saveState] == ""} {
6         source z39util.tcl
7     }
8     if {![info exists debug]} {
9         if {[lindex $sessionParms 0] == "1"} {
10             set debug 1
11         } else {
12             set debug 0
13         }
14     }
15     set mMode 0
16 }
17 <head>
18 <title> Europagate, WWW/Z39.50 Gateway </title>
19 </head>
20 <body>
21 {
22     set useIcons 1
23
24     button-europagate
25     if {[info exists nextSetNo]} {
26         button-view-history 1
27     }
28     button-define-target 0
29     html "<h2>Choose a target</h2><br>\n"
30     html "<dl>\n"
31
32     proc targetsCmp {l r} {
33         global targets
34         return [string compare [string tolower [lindex $targets($l) 0]] \
35                                [string tolower [lindex $targets($r) 0]]]
36     }
37     set tt [array names targets]
38     set tn [lsort -command targetsCmp $tt]
39     foreach t $tn {
40         if {[string index $t 0] == "."} continue
41         html {<dt><a href="http:} $env(SCRIPT_NAME) /
42         html "$sessionId/query.egw;/$t" {"> } [lindex $targets($t) 0] " </a>\n"
43         set desc [lindex $targets($t) 4]
44         if {$desc != ""} {
45             html "<dd>$desc\n"
46         }
47     }
48     html "</dl><br>\n"
49     set useIcons 0
50     button-europagate 
51     if {[info exists nextSetNo]} {
52         button-view-history 1
53     }
54     button-define-target 0
55 }
56 {
57     catch maintenance
58     global debug
59     if {!$debug} return
60     html "<hr>\n"
61     html "<h3>Debug information</h3>\n"
62     html "sessionId: $sessionId <br>\n"
63     html "sessionParms: $sessionParms <br>\n"
64     foreach n [array names env] {
65         html "env($n) = " $env($n) " <br>\n"
66     }
67 }
68 </body>
69 </html>