Html & Script

글자수 체크하기

페이지 정보

본문

<form name='form'>
<b>글자: </b><input type='text' name='t1' onKeyUp='char_count(this.form)'> 
<br><b>글자수: </b><input type='text' name='t2' value='0' readonly="readonly">
</form>
<script language='javascript'>
function char_count(form)
{
 form.t2.value=form.t1.value.length;
}
</script>

관련자료

등록된 댓글이 없습니다.
Today's proverb
우리가 최선을 다해야 하는 이유는 사람들을 감동시키기 위해서가 아니다. 최선을 다할 때만이 자신이 즐겁게 일할 수 있기 때문이다. (앤드류 매튜스)