3 # $Id: nwi.egw,v 1.2 1996/03/12 16:30:27 adam Exp $
6 set scriptQuery nwi.egw
8 set utilExtension nwiutil.tcl
10 if {[info commands saveState] == ""} {
15 if {![info exists debug]} {
16 if {[lindex $sessionParms 1] == "1"} {
22 set html3 [lindex $sessionParms 0]
23 if {[string length $html3] == 0} {
24 if {![info exists env(HTTP_USER_AGENT)]} {
26 } elseif {[string first Mozilla $env(HTTP_USER_AGENT)] == 0} {
28 egw_log debug "New user using Netscape"
31 egw_log debug "New user Not using Netscape"
36 <title> Nordic Web Index, Simple search </title>
45 if {[catch {set setNo $nextSetNo}]} {
53 set initSet [lindex $sessionParms 0]
59 for {set i 1} {$i <= $hist($initSet,0,host)} {incr i} {
60 lappend curTargets $hist($initSet,$i,host)
62 set curSort $hist($initSet,sort)
63 set curFormat $hist($initSet,format)
64 set curEntry $hist($initSet,form,entry1)
67 html {<form action="http:} $env(SCRIPT_NAME)
68 html / $sessionId {/msearch.egw/} $setNo {" method=get>} \n
71 html {<dt><b>Enter your query</b><dd>}
73 html {<input type="text" name="entry1" size=50 value="}
74 html [join $curEntry] {">}
75 html {<input type=submit value="Search"><br>}
77 html {<dt><b>and search the following servers</b><dd>}
80 {nwi.ub2.lu.se/sverige}
81 {nwi.ub2.lu.se/new_nor_lib}
83 {localhost:210/Default}
85 html {<input type="checkbox" name="host" }
86 if {[info exists curTargets]} {
87 if {[lsearch -exact $curTargets $t] != -1} {
91 html {value="} $t {"> } [lindex $targets($t) 0]
93 catch {unset curTargets}
94 html {<p><dt><b>Display each record in <select name="format"><dd>}
95 if {![string compare $curFormat brief]} {
96 html "<option>brief\n"
97 html "<option>medium\n"
99 html "<option>medium\n"
100 html "<option>brief\n"
102 html "</select> notation"
103 html { and sort by <select name="sort">}
104 if {![string compare $curSort score]} {
105 html "<option>score\n"
106 html "<option>server\n"
108 html "<option>server\n"
109 html "<option>score\n"
111 html "</select></b><br></dl>\n"