diff options
author | Eduardo Chappa <echappa@gmx.com> | 2013-02-03 00:59:38 -0700 |
---|---|---|
committer | Eduardo Chappa <echappa@gmx.com> | 2013-02-03 00:59:38 -0700 |
commit | 094ca96844842928810f14844413109fc6cdd890 (patch) | |
tree | e60efbb980f38ba9308ccb4fb2b77b87bbc115f3 /web/cgi/session/logout | |
download | alpine-094ca96844842928810f14844413109fc6cdd890.tar.xz |
Initial Alpine Version
Diffstat (limited to 'web/cgi/session/logout')
l--------- | web/cgi/session/logout/alpine.tcl | 1 | ||||
-rwxr-xr-x | web/cgi/session/logout/logout.tcl | 51 | ||||
l--------- | web/cgi/session/logout/tclsh | 1 |
3 files changed, 53 insertions, 0 deletions
diff --git a/web/cgi/session/logout/alpine.tcl b/web/cgi/session/logout/alpine.tcl new file mode 120000 index 00000000..5ad8d42f --- /dev/null +++ b/web/cgi/session/logout/alpine.tcl @@ -0,0 +1 @@ +../alpine.tcl
\ No newline at end of file diff --git a/web/cgi/session/logout/logout.tcl b/web/cgi/session/logout/logout.tcl new file mode 100755 index 00000000..39587e4e --- /dev/null +++ b/web/cgi/session/logout/logout.tcl @@ -0,0 +1,51 @@ +#!./tclsh + + +# +# and any global config +# + +source ./alpine.tcl + +cgi_eval { + + cgi_input + + if {[catch {cgi_import serverid}]} { + set serverid 0 + } + + catch {cgi_import logerr} + + cgi_http_head { + WPStdHttpHdrs + + # clear cookies + cgi_cookie_set sessid=0 expires=now + } + + if {[info exists env(REMOTE_USER)]} { + set log_text [font class=notice "Protect your privacy![cgi_nl]When you finish, [cgi_url "completely exit your Web browser" http://www.washington.edu/computing/web/logout.html class=notice]."] + append log_text "[cgi_nl][cgi_nl]Or you may want to:" + append log_text "<center><ul>" + if {[catch {cgi_import ppg}]} { + set perpage "" + } else { + set perpage "&ppg=$ppg" + } + + append log_text "<li>[cgi_url "restart Web Alpine" "http://alpine.washington.edu"]" + append log_text "<li>[cgi_url "go to MyUW" "http://myuw.washington.edu"]" + append log_text "</ul></center>" + set log_url "" + } else { + set log_text "Please visit the [cgi_link Start] for a new session." + set log_url $_wp(serverpath)/ + } + + if {[info exists logerr] && [string length $logerr]} { + set log_text "[cgi_bold "Please Note"]: A problem, \"$logerr\", occurred while ending your session.<p>${log_text}" + } + + WPInfoPage "Logged Out" "[font size=+2 face=Helvetica "Thank you for using Alpine"]" $log_text $log_url +} diff --git a/web/cgi/session/logout/tclsh b/web/cgi/session/logout/tclsh new file mode 120000 index 00000000..385fc6c6 --- /dev/null +++ b/web/cgi/session/logout/tclsh @@ -0,0 +1 @@ +../tclsh
\ No newline at end of file |