[LON-CAPA-cvs] cvs: loncom /homework lonhomework.pm /xml lonxml.pm

albertel lon-capa-cvs@mail.lon-capa.org
Fri, 28 Jan 2005 09:49:52 -0000


albertel		Fri Jan 28 04:49:52 2005 EDT

  Modified files:              
    /loncom/homework	lonhomework.pm 
    /loncom/xml	lonxml.pm 
  Log:
  - attempting to correctly set the Last-Modified header. BUG#603
  
  
Index: loncom/homework/lonhomework.pm
diff -u loncom/homework/lonhomework.pm:1.193 loncom/homework/lonhomework.pm:1.194
--- loncom/homework/lonhomework.pm:1.193	Fri Jan 28 04:48:53 2005
+++ loncom/homework/lonhomework.pm	Fri Jan 28 04:49:52 2005
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # The LON-CAPA Homework handler
 #
-# $Id: lonhomework.pm,v 1.193 2005/01/28 09:48:53 albertel Exp $
+# $Id: lonhomework.pm,v 1.194 2005/01/28 09:49:52 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -439,6 +439,8 @@
     if (!$Apache::lonxml::debug && ($ENV{'REQUEST_METHOD'} eq 'GET')) {
 	&Apache::loncommon::no_cache($request);
     }
+    $request->set_last_modified(&Apache::lonnet::metadata($request->uri,
+							  'lastrevisiondate');
     $request->send_http_header;
     return OK if $request->header_only;
     return ''
Index: loncom/xml/lonxml.pm
diff -u loncom/xml/lonxml.pm:1.351 loncom/xml/lonxml.pm:1.352
--- loncom/xml/lonxml.pm:1.351	Mon Jan 24 17:36:03 2005
+++ loncom/xml/lonxml.pm	Fri Jan 28 04:49:52 2005
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # XML Parser Module 
 #
-# $Id: lonxml.pm,v 1.351 2005/01/24 22:36:03 albertel Exp $
+# $Id: lonxml.pm,v 1.352 2005/01/28 09:49:52 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1261,6 +1261,8 @@
 	&Apache::loncommon::content_type($request,'text/html');
     }
     &Apache::loncommon::no_cache($request);
+    $request->set_last_modified(&Apache::lonnet::metadata($request->uri,
+							  'lastrevisiondate');
     $request->send_http_header;
     
     return OK if $request->header_only;