function toUTF8 (strIn) {
var strRet;
var objRegExp=new RegExp("([\\d]+;)","gi");
strRet = strIn.replace(objRegExp,
function(strMatch) {
intCode = strMatch.substring(2,strMatch.length-1);
return String.fromCharCode(intCode);
}
);
return strRet;
}
/*
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
*/
Title:
Convert From windows-1252 To utf-8
Description:
function toUTF8 (strIn) { var strRet; var objRegExp=new RegExp("(&#[\\d]+;)","gi"); strRet = strIn.repla...
...
Rating:
4