--- loncom/lontrans.pm 2004/04/01 20:18:29 1.8 +++ loncom/lontrans.pm 2004/07/02 07:58:01 1.9 @@ -1,7 +1,7 @@ # The LearningOnline Network # URL translation for User Files # -# $Id: lontrans.pm,v 1.8 2004/04/01 20:18:29 raeburn Exp $ +# $Id: lontrans.pm,v 1.9 2004/07/02 07:58:01 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -42,7 +42,10 @@ sub handler { my (undef,undef,$udom,$uname,@ufile)=split(/\//,$fn); $ufile[-1]=~s/^[\~\.]+//; my $chome=&Apache::lonnet::homeserver($uname,$udom); - if ($chome eq $Apache::lonnet::perlvar{'lonHostID'}) { + my $allowed=0; + my @ids=&Apache::lonnet::current_machine_ids(); + foreach my $id (@ids) { if ($id eq $chome) { $allowed=1; } } + if ($allowed) { $r->filename(&Apache::loncommon::propath($udom,$uname). '/userfiles/'.(join('/',@ufile))); }