3 <title> WWW/Z39.50 Gateway Target Definition Response</title>
7 # $Id: tdefine.egw,v 1.1 1996/01/24 14:14:19 adam Exp $
9 if {[info commands saveState] == ""} {
12 html "<h2>Target definition response</h2><br>\n"
14 set name [lindex [egw_form name] 0]
15 set description [lindex [egw_form description] 0]
16 set host [lindex [egw_form host] 0]
17 set databases [lindex [egw_form databases] 0]
18 set authentication [egw_form authentication]
19 set fields [lindex [egw_form fields] 0]
22 if {[string length $name] == 0} {
23 html "You didn't specify a target name. You <em>must</em> specify"
24 html " a target name<br>\n"
27 if {[string length $host] == 0} {
28 html "You didn't specify a target name. You <em>must</em> specify"
29 html " a host name<br>\n"
32 if {[string length $databases] == 0} {
33 html "You didn't specify any database(s). You <em>must</em> specify"
34 html " at least one database</br>\n"
38 catch {unset attrList}
41 set eqn [string first = $e]
43 lappend item {@attr} $e
45 if {[info exists item]} {
46 lappend attrList [list $fname $item]
50 if {[string length $fname] > 0} {
51 set fname "${fname} $e"
57 if {[info exists item]} {
58 lappend attrList [list $fname $item]
60 if {![info exists attrList]} {
61 html "You didn't specify proper search fields. At least one"
62 html " search fields must be present<br>\n"
67 set targets($host) [list \
74 html "Target successfully defined<br>\n"
79 button-define-target 1
88 html "name=" $name "<br>\n"
89 html "description=" $description "<br>\n"
90 html "host=" $host "<br>\n"
91 html "databases=" $databases "<br>\n"
92 html "fields=" $fields "<br>\n"
93 html "attrList=$attrList<br>\n"