Attempt to inform user if session has really terminated.
[egate.git] / www / nwi.egw
index ef66aec..75209c3 100644 (file)
@@ -1,17 +1,12 @@
 <html>
 {
-# $Id: nwi.egw,v 1.2 1996/03/12 16:30:27 adam Exp $
+# $Id: nwi.egw,v 1.4 1996/03/14 11:50:46 adam Exp $
     source ztargets.conf
 
     set scriptQuery nwi.egw
     set scriptTarget {}
     set utilExtension nwiutil.tcl
 
-    if {[info commands saveState] == ""} {
-        source z39util.tcl
-    }
-    set mMode 1
-
     if {![info exists debug]} {
         if {[lindex $sessionParms 1] == "1"} {
             set debug 1
@@ -19,6 +14,9 @@
             set debug 0
         }
     }
+    if {[info commands saveState] == ""} {
+        source z39util.tcl
+    }
     set html3 [lindex $sessionParms 0]
     if {[string length $html3] == 0} {
         if {![info exists env(HTTP_USER_AGENT)]} {
     set useIcons 1
     button-main
 
-    set initSet [lindex $sessionParms 0]
     set curSort score
     set curFormat brief
     set curEntry {}
+
+    set initSet 0
     catch {
-        if {$initSet > 0} {
+        set initSet [lindex $sessionParms 0]
+        if {$initSet < 0} {
+            set initSet 0
+        }
+        if {$initSet} {
             for {set i 1} {$i <= $hist($initSet,0,host)} {incr i} {
                 lappend curTargets $hist($initSet,$i,host)
             }