2012-05-16
일단 소스를 보자.
<script type="text/javascript">
function aa() { alert("hi"); }
</script>
<form name=aaa >
<input type=hidden name="aa" id="aa">
<input type=button onclick="aa();" value="PUSH">
</form>
위와같이 하나의 form 안에 함수와 태그의 이름이 같으면
메시지: 개체가 이 속성 또는 메서드를 지원하지 않습니다.
라는 식으로 오류가 떠버린다.

이것은 form 안에서는 해당 객체의 이름이 같을 경우 자신의 폼을 기본 경로로 불러오기 때문에,
함수 aa(); 가 아닌 input객체 aa를 불러와서 생기는 오류이다.
즉 <input type=button onclick="aa();" value="PUSH">를 <input type=button onclick="window.aa();" value="PUSH">로게 바꾸면 해결 된다.

이것은 해당 form 이름과, 함수이름을 같게 해놓아도 마찬가지이다.