--- rat/lonpageflip.pm 2022/10/19 18:09:03 1.113 +++ rat/lonpageflip.pm 2025/02/07 20:46:01 1.115 @@ -2,7 +2,7 @@ # # Page flip handler # -# $Id: lonpageflip.pm,v 1.113 2022/10/19 18:09:03 raeburn Exp $ +# $Id: lonpageflip.pm,v 1.115 2025/02/07 20:46:01 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -549,7 +549,7 @@ sub handler { if ($reinitcheck eq 'supp') { $possdel = 1; } - my ($supplemental,$refs_updated) = &Apache::lonnet::get_supplemental($cnum,$cdom,'',$possdel); + my ($supplemental,$refs_updated) = &Apache::loncommon::get_supplemental($cnum,$cdom,'',$possdel); unless ($refs_updated) { &Apache::loncommon::set_supp_httprefs($cnum,$cdom,$supplemental); } @@ -563,7 +563,7 @@ sub handler { } else { $furl=&Apache::lonnet::absolute_url().$furl; } - if ($reinitcheck eq 'update') { + if (($reinitcheck eq 'main') || ($reinitcheck eq 'both')) { &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state); $r->print(&reinited_js($furl,$env{'request.course.id'},100)); $r->print(&Apache::loncommon::end_page()); @@ -605,7 +605,7 @@ sub handler { } else { $newloc=&Apache::lonnet::absolute_url().$newloc } - if ($reinitcheck eq 'update') { + if (($reinitcheck eq 'main') || ($reinitcheck eq 'both')) { $r->print(&reinited_js($newloc,$env{'request.course.id'},100)); $r->print(&Apache::loncommon::end_page()); return OK; @@ -632,7 +632,7 @@ sub handler { } else { my $newloc = &Apache::lonnet::absolute_url(). '/adm/navmaps'; - if ($reinitcheck eq 'update') { + if (($reinitcheck eq 'main') || ($reinitcheck eq 'both')) { &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state); $r->print(&reinited_js($newloc,$env{'request.course.id'},100)); $r->print(&Apache::loncommon::end_page()); @@ -747,7 +747,7 @@ sub handler { $url .= $anchor; } } - if ($reinitcheck eq 'update') { + if (($reinitcheck eq 'main') || ($reinitcheck eq 'both')) { &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state); $r->print(&reinited_js($url,$env{'request.course.id'},100)); $r->print(&Apache::loncommon::end_page()); @@ -876,7 +876,7 @@ ENDSTART } } else { # ------------------------------------------------- Problem, could not tie hash - if ($reinitcheck eq 'update') { + if (($reinitcheck eq 'main') || ($reinitcheck eq 'both')) { &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state); $r->print(&Apache::loncommon::end_page()); } @@ -886,7 +886,7 @@ ENDSTART } else { # ---------------------------------------- No, could not determine where we are my $newloc = '/adm/ambiguous'; - if ($reinitcheck eq 'update') { + if (($reinitcheck eq 'main') || ($reinitcheck eq 'both')) { &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state); $r->print(&reinited_js($newloc,$env{'request.course.id'},100)); $r->print(&Apache::loncommon::end_page());