[LON-CAPA-cvs] cvs: rat / lonpage.pm lonratedt.pm

albertel lon-capa-cvs@mail.lon-capa.org
Tue, 21 Oct 2003 20:40:10 -0000


albertel		Tue Oct 21 16:40:10 2003 EDT

  Modified files:              
    /rat	lonratedt.pm lonpage.pm 
  Log:
  - need to recognize when called with target of meta and gracefully return blank (BUG#2022)
  
  
Index: rat/lonratedt.pm
diff -u rat/lonratedt.pm:1.47 rat/lonratedt.pm:1.48
--- rat/lonratedt.pm:1.47	Sun Sep 21 23:02:06 2003
+++ rat/lonratedt.pm	Tue Oct 21 16:40:10 2003
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Edit Handler for RAT Maps
 #
-# $Id: lonratedt.pm,v 1.47 2003/09/22 03:02:06 www Exp $
+# $Id: lonratedt.pm,v 1.48 2003/10/21 20:40:10 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1095,7 +1095,13 @@
   $r->send_http_header;
 
   return OK if $r->header_only;
-
+  my $target = $ENV{'form.grade_target'};
+  if ($target eq 'meta') {
+      &Apache::loncommon::content_type($r,'text/html');
+      $r->send_http_header;
+      return OK;
+  }
+  
   my $url=$r->uri;
   my $fn=&Apache::lonnet::filelocation('',$url);
 
Index: rat/lonpage.pm
diff -u rat/lonpage.pm:1.53 rat/lonpage.pm:1.54
--- rat/lonpage.pm:1.53	Sun Sep 21 23:02:06 2003
+++ rat/lonpage.pm	Tue Oct 21 16:40:10 2003
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Page Handler
 #
-# $Id: lonpage.pm,v 1.53 2003/09/22 03:02:06 www Exp $
+# $Id: lonpage.pm,v 1.54 2003/10/21 20:40:10 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -158,6 +158,12 @@
   my $number_of_columns = 1;
   my $requrl=$r->uri;  
   my $target = $ENV{'form.grade_target'};
+  &Apache::lonnet::logthis("Got a target of $target");
+  if ($target eq 'meta') {
+      &Apache::loncommon::content_type($r,'text/html');
+      $r->send_http_header;
+      return OK;
+  }
 # ----------------------------------------------------------------- Tie db file
   if (($ENV{'request.course.fn'}) && (!$ENV{'form.forceselect'})) {
       my $fn=$ENV{'request.course.fn'};