2006/10/25

Javascript 跟 ASCII 轉換

// javascript 的charCodeAt 是取得字串的ASCII編碼
String.charCodeAt();

//num 為十進位的ASCII編碼,此formCharCode將取得對應ASCII的字串
String.fromCharCode(num);

No comments: