[LON-CAPA-cvs] cvs: loncom /lonnet/perl lonnet.pm

albertel lon-capa-cvs@mail.lon-capa.org
Tue, 10 Jan 2006 16:08:11 -0000


albertel		Tue Jan 10 11:08:11 2006 EDT

  Modified files:              
    /loncom/lonnet/perl	lonnet.pm 
  Log:
  - adding EXT args possibilities of 'resource.title' and 'resource.map'
  
  
  
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.692 loncom/lonnet/perl/lonnet.pm:1.693
--- loncom/lonnet/perl/lonnet.pm:1.692	Tue Jan 10 11:06:07 2006
+++ loncom/lonnet/perl/lonnet.pm	Tue Jan 10 11:08:10 2006
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # TCP networking package
 #
-# $Id: lonnet.pm,v 1.692 2006/01/10 16:06:07 albertel Exp $
+# $Id: lonnet.pm,v 1.693 2006/01/10 16:08:10 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -4823,11 +4823,21 @@
         return $env{'course.'.$courseid.'.'.$spacequalifierrest};
     } elsif ($realm eq 'resource') {
 
-	my $section;
-        my @groups = ();
 	if (defined($courseid) && $courseid eq $env{'request.course.id'}) {
 	    if (!$symbparm) { $symbparm=&symbread(); }
 	}
+
+	if ($space eq 'title') {
+	    if (!$symbparm) { $symbparm = $env{'request.filename'}; }
+	    return &gettitle($symbparm);
+	}
+	
+	if ($space eq 'map') {
+	    my ($map) = &decode_symb($symbparm);
+	    return &symbread($map);
+	}
+
+	my ($section, $group, @groups);
 	my ($courselevelm,$courselevel);
 	if ($symbparm && defined($courseid) && 
 	    $courseid eq $env{'request.course.id'}) {