-
-
@@ -2206,7 +2191,11 @@ sub redirect_back {
}
$feedurl=&Apache::lonenc::check_encrypt($feedurl);
my $logo=&Apache::loncommon::lonhttpdurl('/adm/lonIcons/lonlogos.gif');
- my %onload = ('onload' => "if (window.name!='loncapaclient') { this.document.reldt.submit(); self.window.close(); }");
+ my %onload;
+ if ($env{'environment.remote'} ne 'off') {
+ $onload{'onload'} =
+ "if (window.name!='loncapaclient') { this.document.reldt.submit(); self.window.close(); }";
+ }
my $start_page=
&Apache::loncommon::start_page('New posts marked as read',undef,
{'redirect' => [2,$feedurl],
@@ -2237,9 +2226,15 @@ sub no_redirect_back {
my ($r,$feedurl) = @_;
my $nofeed=&mt('Sorry, no feedback possible on this resource ...');
+ my %onload;
+ if ($env{'environment.remote'} ne 'off') {
+ $onload{'onload'} =
+ "if (window.name!='loncapaclient') { self.window.close(); }";
+ }
+
my %body_options = ('only_body' => 1,
'bgcolor' => '#FFFFFF',
- 'add_entries' => {'onload' => "if (window.name!='loncapaclient') { self.window.close(); }"});
+ 'add_entries' => \%onload,);
if ($feedurl !~ m{^/adm/feedback}) {
$body_options{'rediect'} = [2,$feedurl];
@@ -2268,23 +2263,23 @@ sub screen_header {
unless (($env{'form.replydisc'}) || ($env{'form.editdisc'})) {
if (($feedurl=~/^\/res\//) && ($feedurl!~/^\/res\/adm/) && ($env{'user.adv'})) {
$msgoptions=
- ' |