--- loncom/interface/loncommon.pm 2013/09/21 13:56:22 1.1156
+++ loncom/interface/loncommon.pm 2013/11/25 20:18:55 1.1159
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# a pile of common routines
#
-# $Id: loncommon.pm,v 1.1156 2013/09/21 13:56:22 raeburn Exp $
+# $Id: loncommon.pm,v 1.1159 2013/11/25 20:18:55 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1388,7 +1388,7 @@ sub top_nav_help {
return <<"END";
$banner_link
- $text
+$text
END
}
@@ -5284,7 +5284,7 @@ sub make_attr_string {
}
my $attr_string;
- foreach my $attr (keys(%$attr_ref)) {
+ foreach my $attr (sort(keys(%$attr_ref))) {
$attr_string .= " $attr=\"".$attr_ref->{$attr}.'" ';
}
return $attr_string;
@@ -7355,7 +7355,7 @@ sub font_settings {
my $headerstring='';
if (!$env{'browser.mathml'} && $env{'browser.unicode'}) {
$headerstring.=
- '';
+ ''."\n";
}
return $headerstring;
}
@@ -7459,8 +7459,8 @@ sub xml_begin {
.'';
} else {
- $output=''
- .'';
+ $output=''."\n"
+ .''."\n";
}
return $output;
}
@@ -9876,12 +9876,13 @@ sub ask_for_embedded_content {
} else {
$embed_file = $file;
}
- my $absolutepath;
- my $cleaned_file = &clean_path($embed_file);
- if ($cleaned_file =~ m{^\w+://}) {
+ my ($absolutepath,$cleaned_file);
+ if ($embed_file =~ m{^\w+://}) {
+ $cleaned_file = $embed_file;
$newfiles{$cleaned_file} = 1;
$mapping{$cleaned_file} = $embed_file;
} else {
+ $cleaned_file = &clean_path($embed_file);
if ($embed_file =~ m{^/}) {
$absolutepath = $embed_file;
}
@@ -14414,6 +14415,12 @@ sub init_user_environment {
$env{'browser.interface'}=$form->{'interface'};
}
+ if ($form->{'iptoken'}) {
+ my $lonhost = $r->dir_config('lonHostID');
+ $initial_env{"user.noloadbalance"} = $lonhost;
+ $env{'user.noloadbalance'} = $lonhost;
+ }
+
my %is_adv = ( is_adv => $env{'user.adv'} );
my %domdef;
unless ($domain eq 'public') {