--- loncom/auth/lonroles.pm 2018/01/09 15:44:43 1.336 +++ loncom/auth/lonroles.pm 2018/04/28 00:57:58 1.337 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # User Roles Screen # -# $Id: lonroles.pm,v 1.336 2018/01/09 15:44:43 raeburn Exp $ +# $Id: lonroles.pm,v 1.337 2018/04/28 00:57:58 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -153,20 +153,26 @@ sub redirect_user { &Apache::loncommon::no_cache($r); $r->send_http_header; - # Breadcrumbs - my $brcrum = [{'href' => $url, - 'text' => 'Switching Role'},]; - my $start_page = &Apache::loncommon::start_page('Switching Role',undef, - {'redirect' => [1,$url], - 'bread_crumbs' => $brcrum,}); - my $end_page = &Apache::loncommon::end_page(); + my $start_page; + if ($env{'request.lti.login'}) { + $start_page = &Apache::loncommon::start_page(undef,undef, + {'redirect' => [0,$url],}).$msg; + } else { + # Breadcrumbs + my $brcrum = [{'href' => $url, + 'text' => 'Switching Role'},]; + $start_page = &Apache::loncommon::start_page('Switching Role',undef, + {'redirect' => [1,$url], + 'bread_crumbs' => $brcrum,}). + "\n
$msg
"; + } + my $end_page = &Apache::loncommon::end_page(); # Note to style police: # This must only replace the spaces, nothing else, or it bombs elsewhere. $url=~s/ /\%20/g; $r->print(<