--- loncom/interface/lonfeedback.pm 2008/06/06 05:24:28 1.255 +++ loncom/interface/lonfeedback.pm 2008/12/21 16:18:04 1.255.2.2 @@ -1,7 +1,7 @@ # The LearningOnline Network # Feedback # -# $Id: lonfeedback.pm,v 1.255 2008/06/06 05:24:28 raeburn Exp $ +# $Id: lonfeedback.pm,v 1.255.2.2 2008/12/21 16:18:04 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -625,7 +625,7 @@ END $filterchoice .= ' '.$role_types{$role}.','; } $filterchoice =~ s/,$//; - $filterchoice .= '
        '; + $filterchoice .= '
'.(' ' x8); } if ($statusfilter) { $filterchoice .= ''.&mt('status').'- '.$status_types{$statusfilter}; @@ -794,7 +794,7 @@ sub action_links_bar { $discussion .= '&previous='.$prevread; } $discussion .= &group_args($group); - $discussion .='">'.&mt('Sorting/Filtering options').'  '; + $discussion .='">'.&mt('Sorting/Filtering options').''.(' ' x2); } else { $discussion .= ''; } @@ -3247,12 +3247,18 @@ function setblogvalue() { sub has_discussion { my $resourcesref = shift; my $navmap = Apache::lonnavmaps::navmap->new(); - my @allres=$navmap->retrieveResources(); - foreach my $resource (@allres) { - if ($resource->hasDiscussion()) { - my $ressymb = $resource->wrap_symb(); - push(@{$resourcesref}, $ressymb); + if (defined($navmap)) { + my @allres=$navmap->retrieveResources(); + foreach my $resource (@allres) { + if ($resource->hasDiscussion()) { + my $ressymb = $resource->wrap_symb(); + if (ref($resourcesref) eq 'ARRAY') { + push(@{$resourcesref}, $ressymb); + } + } } + } else { + &Apache::lonnet::logthis('Has discussion check failed - could not create navmap object.'); } return; } @@ -3654,7 +3660,7 @@ ENDREDIR } else { # ------------------------------------------------------------- Normal feedback my $feedurl=$env{'form.postdata'}; - $feedurl=~s/^http\:\/\///; + $feedurl=~s/^https?\:\/\///; $feedurl=~s/^$ENV{'SERVER_NAME'}//; $feedurl=~s/^$ENV{'HTTP_HOST'}//; $feedurl=~s/\?.+$//;