문자 byte1 문자 byte 수 체크하기 function check_msglen() { var length = calculate_msglen(document.getElementById('content').value); document.getElementById('byte').value = length; } function calculate_msglen(message) { var nbytes = 0; for (i=0; i 4) { nbytes += 2; } else if (ch != '\r') { nbytes++; } } return nbytes; } ================================== onkeyup="(12, this.name);" // 제한 byte 길이, 객체 이름 // 글자 byte 계산 function chec.. 2013. 12. 5. 이전 1 다음