[LON-CAPA-cvs] cvs: loncom / loncapa_apache.conf /localize lonlocal.pm

raeburn raeburn@source.lon-capa.org
Wed, 07 Jul 2010 16:30:49 -0000


raeburn		Wed Jul  7 16:30:49 2010 EDT

  Modified files:              
    /loncom	loncapa_apache.conf 
    /loncom/localize	lonlocal.pm 
  Log:
  - Browser detection needs to set browser.unicode for IE if charset for page is UTF-8
    and there is a possibility TTH will be used.
  
  
Index: loncom/loncapa_apache.conf
diff -u loncom/loncapa_apache.conf:1.195 loncom/loncapa_apache.conf:1.196
--- loncom/loncapa_apache.conf:1.195	Thu Mar 18 13:16:06 2010
+++ loncom/loncapa_apache.conf	Wed Jul  7 16:30:44 2010
@@ -1,7 +1,7 @@
 ##
 ## loncapa_apache.conf -- Apache HTTP LON-CAPA configuration file
 ##
-## $Id: loncapa_apache.conf,v 1.195 2010/03/18 13:16:06 raeburn Exp $
+## $Id: loncapa_apache.conf,v 1.196 2010/07/07 16:30:44 raeburn Exp $
 ##
 
 #
@@ -1451,7 +1451,7 @@
 # - a number that describes the minimum version that has mathml support
 # - a number that describes the minimum number version that has unicode support
 
-PerlSetVar       lonBrowsDet  explorer:msie:netscape:msie\s(\d+\.\d+)\;:9999:9999&mozilla:mozilla\/[5-9]:msie:mozilla\/(\d+\.\d+)\s:9999:1&netscape:netscape:msie:netscape\/(\d+\.\d+):9999:7&netscape:netscape\/[7-9]:shouldnotmatch:netscape\/(\d+\.\d+):9999:7&amaya:amaya:mozilla:V(\d+\.\d+)\s:1:1&safari:safari:msie:safari\/([\d\.]+):9999:84
+PerlSetVar       lonBrowsDet  explorer:msie:netscape:msie\s(\d+\.\d+)\;:9999:5&mozilla:mozilla\/[5-9]:msie:mozilla\/(\d+\.\d+)\s:9999:1&netscape:netscape:msie:netscape\/(\d+\.\d+):9999:7&netscape:netscape\/[7-9]:shouldnotmatch:netscape\/(\d+\.\d+):9999:7&amaya:amaya:mozilla:V(\d+\.\d+)\s:1:1&safari:safari:msie:safari\/([\d\.]+):9999:84
 
 PerlSetVar       lonTextBrowsers windows\s+ce:lynx
 PerlSetVar       lonScansDir  /home/httpd/scantron
Index: loncom/localize/lonlocal.pm
diff -u loncom/localize/lonlocal.pm:1.60 loncom/localize/lonlocal.pm:1.61
--- loncom/localize/lonlocal.pm:1.60	Thu Oct  1 20:22:33 2009
+++ loncom/localize/lonlocal.pm	Wed Jul  7 16:30:48 2010
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Localization routines
 #
-# $Id: lonlocal.pm,v 1.60 2009/10/01 20:22:33 raeburn Exp $
+# $Id: lonlocal.pm,v 1.61 2010/07/07 16:30:48 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -295,13 +295,12 @@
 
 sub current_encoding {
     my $default='UTF-8';
-# UTF-8 character encoding needed for the whole LON-CAPA system
-# (interface language and homework problem content)
-# See Bugzilla 5702 vs. 2189 and 4067
-#    if ($Apache::lonnet::env{'browser.os'} eq 'win' && 
-#	$Apache::lonnet::env{'browser.type'} eq 'explorer') {
-#        $default='ISO-8859-1';
-#    }
+    unless ($Apache::lonnet::env{'browser.unicode'}) {
+        if ($Apache::lonnet::env{'browser.os'} eq 'win' && 
+	    $Apache::lonnet::env{'browser.type'} eq 'explorer') {
+            $default='ISO-8859-1';
+        }
+    }
     if ($lh) {
 	my $enc=$lh->maketext('char_encoding');
 	return ($enc eq 'char_encoding'?$default:$enc);