Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

remove use of get_String("thischarset") replace it with utf-8 MDL-7570

  • Loading branch information...
commit e3bc1066215e0b18134ceb12577a9967880367dd 1 parent 70ad6fd
skodak authored
View
2  admin/lang.php
@@ -384,7 +384,7 @@
$enstring = $string;
if ($currentlang != 'en' and $currentfile == 'moodle.php') {
$enstring['thislanguage'] = "<< TRANSLATORS: Specify the name of your language here. If possible use Unicode Numeric Character References >>";
- $enstring['thischarset'] = "<< TRANSLATORS: Specify the character set of your language here. Note that all text created while this language is active will be stored using this character set, so don't change it once you have set it. Example: iso-8859-1 >>";
+ $enstring['thischarset'] = "<< TRANSLATORS: Charset encoding - always use utf-8 >>";
$enstring['thisdirection'] = "<< TRANSLATORS: This string specifies the direction of your text, either left-to-right or right-to-left. Insert either 'ltr' or 'rtl' here. >>";
$enstring['parentlanguage'] = "<< TRANSLATORS: If your language has a Parent Language that Moodle should use when strings are missing from your language pack, then specify the code for it here. If you leave this blank then English will be used. Example: nl >>";
}
View
4 filter/tex/displaytex.php
@@ -8,12 +8,12 @@
// entities are usually encoded twice, first in HTML editor then in tex/filter.php
$texexp = html_entity_decode(html_entity_decode($texexp));
// encode all entities (saves non-ISO)
- $texexp = htmlentities($texexp,ENT_COMPAT,get_string("thischarset","moodle"));
+ $texexp = htmlentities($texexp,ENT_COMPAT,'utf-8');
?>
<html>
<head>
<title>TeX Source</title>
- <meta http-equiv="content-type" content="text/html; charset=<?php echo get_string('thischarset'); ?>" />
+ <meta http-equiv="content-type" content="text/html; charset=utf-8" />
</head>
<body bgcolor="#FFFFFF">
<?php echo $texexp; ?>
View
2  lib/editor/htmlarea/coursefiles.php
@@ -47,7 +47,7 @@ function html_header($course, $wdir, $formfield=""){
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
- <meta http-equiv="content-type" content="text/html; charset=<?php print_string("thischarset");?>" />
+ <meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>coursefiles</title>
<script language="javscript" type="text/javascript">
<!--
View
5 lib/editor/htmlarea/htmlarea.php
@@ -13,8 +13,7 @@
// ob_start("ob_gzhandler");
//}
- $charset = get_string('thischarset');
- header("Content-type: application/x-javascript; charset: $charset"); // Correct MIME type
+ header("Content-type: application/x-javascript; charset: utf-8"); // Correct MIME type
header("Last-Modified: " . gmdate("D, d M Y H:i:s", $lastmodified) . " GMT");
header("Expires: " . gmdate("D, d M Y H:i:s", time() + $lifetime) . " GMT");
header("Cache-control: max_age = $lifetime");
@@ -694,7 +693,7 @@ function createButton(txt) {
if (!editor.config.fullPage) {
html = "<html>\n";
html += "<head>\n";
- html += '<meta http-equiv="content-type" content="text/html; charset=<?php echo $charset; ?>" />\n';
+ html += '<meta http-equiv="content-type" content="text/html; charset=utf-8" />\n';
if (editor.config.baseURL)
html += '<base href="' + editor.config.baseURL + '" />';
html += '<style type="text/css">\n' + editor.config.pageStyle + "td { border: 1px dotted gray; }</style>\n";
View
3  lib/editor/htmlarea/lang/en.php
@@ -10,8 +10,7 @@
// ob_start("ob_gzhandler");
//}
- $charset = get_string('thischarset');
- header("Content-type: application/x-javascript; charset: $charset"); // Correct MIME type
+ header("Content-type: application/x-javascript; charset: utf-8"); // Correct MIME type
header("Last-Modified: " . gmdate("D, d M Y H:i:s", $lastmodified) . " GMT");
header("Expires: " . gmdate("D, d M Y H:i:s", time() + $lifetime) . " GMT");
// See Bug #2387
View
2  lib/editor/htmlarea/popups/createanchor.php
@@ -5,7 +5,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
-<meta http-equiv="content-type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>Create anchor</title>
<script language="javascript" type="text/javascript" src="popup.js"></script>
<script language="javascript" type="text/javascript">
View
4 lib/editor/htmlarea/popups/dlg_ins_char.php
@@ -51,7 +51,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
-<meta http-equiv="content-type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<style type="text/css">
<!--
body { background: ButtonFace; color: ButtonText; font: 11px Tahoma,Verdana,sans-serif;
@@ -73,7 +73,7 @@
function Init() {
__dlg_init();
}
-var chars = ["!","&quot;","#","$","%","&","'","(",")","*","+","-",".","/","0","1","2","3","4","5","6","7","8","9",":",";","&lt;","=","&gt;","?","@","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","[","]","^","_","`","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","{","|","}","~","&euro;","ƒ","„","…","†","‡","ˆ","\‰","Š","‹","Œ","&lsquo;","&rsquo;","&rsquo;","&ldquo;","&rdquo;","•","&ndash;","&mdash;","˜","™","š","›","œ","Ÿ","&iexcl;","&cent;","&pound;","&pound;","&curren;","&yen;","&brvbar;","&sect;","&uml;","&copy;","&ordf;","&laquo;","&not;","­","&reg;","&macr;","&deg;","&plusmn;","&sup2;","&sup3;","&acute;","&micro;","&para;","&middot;","&cedil;","&sup1;","&ordm;","&raquo;","&frac14;","&frac12;","&frac34;","&iquest;","&Agrave;","&Aacute;","&Acirc;","&Atilde;","&Auml;","&Aring;","&AElig;","&Ccedil;","&Egrave;","&Eacute;","&Ecirc;","&Euml;","&Igrave;","&Iacute;","&Icirc;","&Iuml;","&ETH;","&Ntilde;","&Ograve;","&Oacute;","&Ocirc;","&Otilde;","&Ouml;","&times;","&Oslash;","&Ugrave;","&Uacute;","&Ucirc;","&Uuml;","&Yacute;","&THORN;","&szlig;","&agrave;","&aacute;","&acirc;","&atilde;","&auml;","&aring;","&aelig;","&ccedil;","&egrave;","&eacute;","&ecirc;","&euml;","&igrave;","&iacute;","&icirc;","&iuml;","&eth;","&ntilde;","&ograve;","&oacute;","&ocirc;","&otilde;","&ouml;","&divide;","&oslash;","&ugrave;","&uacute;","&ucirc;","&uuml;","&uuml;","&yacute;","&thorn;","&yuml;"]
+var chars = ["!","&quot;","#","$","%","&","'","(",")","*","+","-",".","/","0","1","2","3","4","5","6","7","8","9",":",";","&lt;","=","&gt;","?","@","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","[","]","^","_","`","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","{","|","}","~","&euro;","ƒ","„","…","†","‡","ˆ","\‰","Š","‹","Œ","&lsquo;","&rsquo;","&rsquo;","&ldquo;","&rdquo;","•","&ndash;","&mdash;","˜","™","š","›","œ","Ÿ","&iexcl;","&cent;","&pound;","&pound;","&curren;","&yen;","&brvbar;","&sect;","&uml;","&copy;","&ordf;","&laquo;","&not;","­","&reg;","&macr;","&deg;","&plusmn;","&sup2;","&sup3;","&acute;","&micro;","&para;","&middot;","&cedil;","&sup1;","&ordm;","&raquo;","&frac14;","&frac12;","&frac34;","&iquest;","&Agrave;","&Aacute;","&Acirc;","&Atilde;","&Auml;","&Aring;","&AElig;","&Ccedil;","&Egrave;","&Eacute;","&Ecirc;","&Euml;","&Igrave;","&Iacute;","&Icirc;","&Iuml;","&ETH;","&Ntilde;","&Ograve;","&Oacute;","&Ocirc;","&Otilde;","&Ouml;","&times;","&Oslash;","&Ugrave;","&Uacute;","&Ucirc;","&Uuml;","&Yacute;","&THORN;","&szlig;","&agrave;","&aacute;","&acirc;","&atilde;","&auml;","&aring;","&aelig;","&ccedil;","&egrave;","&eacute;","&ecirc;","&euml;","&igrave;","&iacute;","&icirc;","&iuml;","&eth;","&ntilde;","&ograve;","&oacute;","&ocirc;","&otilde;","&ouml;","&divide;","&oslash;","&ugrave;","&uacute;","&ucirc;","&uuml;","&uuml;","&yacute;","&thorn;","&yuml;"]
function tab(w,h) {
var strtab = ["<table border='0' cellspacing='0' cellpadding='0' align='center' bordercolor='#dcdcdc' bgcolor='#C0C0C0'>"]
View
2  lib/editor/htmlarea/popups/dlg_ins_smile.php
@@ -37,7 +37,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
-<meta http-equiv="content-type" content="text/html; charset=<?php print_string('thischarset'); ?>" />
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title><?php print_string('insertsmile', 'editor'); ?></title>
<link rel="stylesheet" href="dialog.css" type="text/css" />
<script language="javascript" type="text/javascript" src="popup.js"></script>
View
8 lib/editor/htmlarea/popups/fullscreen.php
@@ -9,7 +9,7 @@
?>
<html>
<head><title><?php print_string("fullscreen","editor");?></title>
-<meta http-equiv="content-type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<style type="text/css">
@import url(../htmlarea.css);
html, body { margin: 0px; border: 0px; background-color: buttonface; } </style>
@@ -17,9 +17,9 @@
<script type="text/javascript" src="../htmlarea.php?id=<?php p($id); ?>"></script>
<script type="text/javascript" src="../lang/en.php"></script>
-<script type="text/javascript" src="../dialog.js" charset="<?php print_string('thischarset'); ?>"></script>
-<script type="text/javascript" src="../plugins/TableOperations/table-operations.js" charset="<?php print_string('thischarset'); ?>"></script>
-<script type="text/javascript" src="../plugins/TableOperations/lang/en.js" charset="<?php print_string('thischarset'); ?>"></script>
+<script type="text/javascript" src="../dialog.js" charset="utf-8"></script>
+<script type="text/javascript" src="../plugins/TableOperations/table-operations.js" charset="utf-8"></script>
+<script type="text/javascript" src="../plugins/TableOperations/lang/en.js" charset="utf-8"></script>
<script type="text/javascript">
// load same scripts that were present in the opener page
var scripts = opener.document.getElementsByTagName("script");
View
2  lib/editor/htmlarea/popups/insert_image.php
@@ -15,7 +15,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
-<meta http-equiv="content-type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title><?php print_string("insertimage","editor");?></title>
<script language="javascript" type="text/javascript" src="popup.js"></script>
<script language="javascript" type="text/javascript">
View
2  lib/editor/htmlarea/popups/insert_image_std.php
@@ -13,7 +13,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
-<meta http-equiv="content-type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title><?php print_string("insertimage","editor");?></title>
<script language="javascript" type="text/javascript" src="popup.js"></script>
View
2  lib/editor/htmlarea/popups/insert_table.php
@@ -5,7 +5,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
-<meta http-equiv="content-type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title><?php print_string("inserttable","editor");?></title>
<script language="javascript" type="text/javascript" src="popup.js"></script>
<script language="javascript" type="text/javascript">
View
2  lib/editor/htmlarea/popups/link.php
@@ -12,7 +12,7 @@
<html>
<head>
<title><?php print_string("insertlink","editor");?></title>
-<meta http-equiv="Content-Type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script language="javascript" type="text/javascript">
function onCancel() {
View
2  lib/editor/htmlarea/popups/link_std.php
@@ -12,7 +12,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
-<meta http-equiv="Content-Type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><?php print_string("insertlink","editor");?></title>
<script language="javascript" type="text/javascript" src="popup.js"></script>
<script language="javascript" type="text/javascript">
View
2  lib/editor/htmlarea/popups/searchandreplace.php
@@ -5,7 +5,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
-<meta http-equiv="content-type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title><?php print_string("searchandreplace","editor");?></title>
<script language="javascript" type="text/javascript" src="popup.js"></script>
<script language="javascript" type="text/javascript">
View
2  lib/editor/htmlarea/popups/select_color.php
@@ -5,7 +5,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
-<meta http-equiv="content-type" content="text/html; charset=<?php print_string("thischarset");?>" />
+<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title><?php print_string("selectcolor","editor");?></title>
<style type="text/css">
html, body { width: 238; height: 188; }
Please sign in to comment.
Something went wrong with that request. Please try again.