"자바스크립트 onchange 이벤트"의 두 판 사이의 차이

잔글 (Jmnote 사용자가 JavaScript onChange 문서를 자바스크립트 onchange 이벤트 문서로 옮겼습니다)
5번째 줄: 5번째 줄:


==소스 코드==
==소스 코드==
<source lang='dos'>
<source lang='html5'>
<input type="text" value="hello" onchange="bgcolor_yellow(this)" />
<input type="text" value="world" onchange="bgcolor_yellow(this)" />
 
<script>
function bgcolor_yellow(obj) {
  obj.style.backgroundColor = 'yellow';
}
</script>
</source>
</source>



2014년 7월 10일 (목) 22:05 판

1 개요

JavaScript onchange Event
자바스크립트 onchange 이벤트

2 소스 코드

<input type="text" value="hello" onchange="bgcolor_yellow(this)" />
<input type="text" value="world" onchange="bgcolor_yellow(this)" />

<script>
function bgcolor_yellow(obj) {
  obj.style.backgroundColor = 'yellow';
}
</script>

3 같이 보기

4 참고 자료

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}