--- loncom/interface/selfenroll.pm 2016/08/07 01:40:55 1.27.2.5 +++ loncom/interface/selfenroll.pm 2021/06/20 16:23:21 1.27.2.7 @@ -1,7 +1,7 @@ # The LearningOnline Network # Allow users to self-enroll in a course # -# $Id: selfenroll.pm,v 1.27.2.5 2016/08/07 01:40:55 raeburn Exp $ +# $Id: selfenroll.pm,v 1.27.2.7 2021/06/20 16:23:21 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -665,9 +665,10 @@ sub pending_selfenrollment_form { if ($buttontext eq '') { $buttontext = &mt('Complete my enrollment'); } + my $hostname = &Apache::lonnet::hostname($lonhost); my $protocol = $Apache::lonnet::protocol{$lonhost}; $protocol = 'http' if ($protocol ne 'https'); - my $enroller = $protocol.'://'.&Apache::lonnet::hostname($lonhost).'/cgi-bin/enrollqueued.pl'; + my $enroller = $protocol.'://'.$hostname.'/cgi-bin/enrollqueued.pl'; $output .= ''."\n". ''."\n". ''."\n". @@ -792,7 +793,7 @@ sub check_registered { 'internal.sectionnums', 'internal.crosslistings'],$cdom,$cnum); my (@allcourses,%LC_code,%affiliates,%reply); - &Apache::loncommon::get_institutional_codes(\%settings,\@allcourses,\%LC_code); + &Apache::loncommon::get_institutional_codes($cdom,$cnum,\%settings,\@allcourses,\%LC_code); if (@allcourses > 0) { @{$affiliates{$cnum}} = @allcourses; my $outcome = &Apache::lonnet::fetch_enrollment_query('updatenow',\%affiliates,\%reply,$cdom,$cnum);