--- loncom/interface/lonnavdisplay.pm 2013/08/08 01:54:51 1.22.4.2
+++ loncom/interface/lonnavdisplay.pm 2014/05/22 12:25:32 1.22.4.5
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
-# Navigate Maps Handler
+# Navigate Maps Display Handler
#
-# $Id: lonnavdisplay.pm,v 1.22.4.2 2013/08/08 01:54:51 raeburn Exp $
+# $Id: lonnavdisplay.pm,v 1.22.4.5 2014/05/22 12:25:32 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -30,7 +30,7 @@
package Apache::lonnavdisplay;
use strict;
-use Apache::Constants qw(:common :http);
+use Apache::Constants qw(:common :http REDIRECT);
use Apache::lonmenu();
use Apache::loncommon();
use Apache::lonnavmaps();
@@ -38,7 +38,7 @@ use Apache::lonhtmlcommon();
use Apache::lonnet;
use Apache::lonlocal;
use Apache::londocs();
-use Time::HiRes qw( gettimeofday tv_interval );
+#use Time::HiRes qw( gettimeofday tv_interval );
sub handler {
my $r = shift;
@@ -59,6 +59,14 @@ sub real_handler {
return OK;
}
+ # Check for critical messages and redirect if present.
+ my ($redirect,$url) = &Apache::loncommon::critical_redirect(300);
+ if ($redirect) {
+ &Apache::loncommon::content_type($r,'text/html');
+ $r->header_out(Location => $url);
+ return REDIRECT;
+ }
+
# Send header, don't cache this page
if ($env{'browser.mathml'}) {
&Apache::loncommon::content_type($r,'text/xml');
@@ -246,7 +254,7 @@ sub real_handler {