--- loncom/interface/loncommon.pm 2004/11/30 22:57:16 1.236 +++ loncom/interface/loncommon.pm 2004/12/02 00:01:34 1.238 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # a pile of common routines # -# $Id: loncommon.pm,v 1.236 2004/11/30 22:57:16 albertel Exp $ +# $Id: loncommon.pm,v 1.238 2004/12/02 00:01:34 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -2606,8 +2606,8 @@ ENDROLE ($ENV{'request.filename'} =~ m|^/home/([^/]+)/public_html/(.*)|); my $formaction='/priv/'.$uname.'/'.$thisdisfn; $formaction=~s/\/+/\//g; - unless ($customtitle) { - my $parentpath = $thisdisfn; + unless ($customtitle) { #this is for resources; directories have customtitle, and crumbs and select recent are created in lonpubdir.pm + my $parentpath = ''; if ($thisdisfn =~ m-(.+/)[^/]*$-) { $parentpath = $1; } @@ -3887,7 +3887,7 @@ sub escape_double { # Escapes the last element of a full URL. sub escape_url { my ($url) = @_; - my @urlslices = split(/\//, $url); + my @urlslices = split(/\//, $url,-1); my $lastitem = &Apache::lonnet::escape(pop(@urlslices)); return join('/',@urlslices).'/'.$lastitem; }