[LON-CAPA-cvs] cvs: loncom /interface loncommon.pm
raeburn
raeburn at source.lon-capa.org
Mon Nov 25 15:18:56 EST 2013
raeburn Mon Nov 25 20:18:56 2013 EDT
Modified files:
/loncom/interface loncommon.pm
Log:
- Consistent order for attributes in <body> tag to facilitate debugging.
- Add some line feeds to improve readability of source HTML.
Index: loncom/interface/loncommon.pm
diff -u loncom/interface/loncommon.pm:1.1158 loncom/interface/loncommon.pm:1.1159
--- loncom/interface/loncommon.pm:1.1158 Sat Nov 16 19:56:02 2013
+++ loncom/interface/loncommon.pm Mon Nov 25 20:18:55 2013
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# a pile of common routines
#
-# $Id: loncommon.pm,v 1.1158 2013/11/16 19:56:02 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 @@
return <<"END";
$banner_link
- <a href="$link" title="$title">$text</a>
+<a href="$link" title="$title">$text</a>
END
}
@@ -5284,7 +5284,7 @@
}
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 @@
my $headerstring='';
if (!$env{'browser.mathml'} && $env{'browser.unicode'}) {
$headerstring.=
- '<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />';
+ '<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />'."\n";
}
return $headerstring;
}
@@ -7459,8 +7459,8 @@
.'<html xmlns:math="http://www.w3.org/1998/Math/MathML" '
.'xmlns="http://www.w3.org/1999/xhtml">';
} else {
- $output='<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">'
- .'<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">';
+ $output='<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">'."\n"
+ .'<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">'."\n";
}
return $output;
}
More information about the LON-CAPA-cvs
mailing list