--- loncom/auth/switchserver.pm 2007/11/14 02:54:11 1.18 +++ loncom/auth/switchserver.pm 2007/11/15 01:16:32 1.20 @@ -1,7 +1,7 @@ # The LearningOnline Network # Switch Servers Handler # -# $Id: switchserver.pm,v 1.18 2007/11/14 02:54:11 albertel Exp $ +# $Id: switchserver.pm,v 1.20 2007/11/15 01:16:32 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -92,7 +92,7 @@ sub handler { if ($env{'user.name'} eq 'public' && $env{'user.domain'} eq 'public') { - my $url = 'http://'.$switch_to.'/'.$r->uri; + my $url = 'http://'.$switch_to.$r->uri; return &do_redirect($r,$url,1) } @@ -115,8 +115,11 @@ sub handler { -value => '', -expires => '-10y',); $r->header_out('Set-cookie' => $c); - $r->send_http_header; - return OK if $r->header_only; + + if ($r->header_only) { + $r->send_http_header; + return OK; + } # -------------------------------------------------------- Menu script and info my $windowinfo=