📜  javascript hex to string - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:01:11.096000             🧑  作者: Mango

代码示例1
function hex_to_ascii(str1)
 {
    var hex  = str1.toString();
    var str = '';
    for (var n = 0; n < hex.length; n += 2) {
        str += String.fromCharCode(parseInt(hex.substr(n, 2), 16));
    }
    return str;
 }