내가 외부 JS 파일을로드하는 외부 JS 파일에서, 신체 내부의 함수를 호출 body onLoad 이벤트가 발생하기 전에 몸체 내부에()를 삽입해야합니다. Here, 나는 all these solutions을 시도했습니다 : 첫 번째 작품 만,하지만 그것을 피하고 싶습니다. 예를 들어동적으로
는 솔루션 2는 다음과 같습니다
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<script type="text/javascript"></script>
<script type="text/javascript">
document.getElementsByTagName("head")[0].getElementsByTagName("script")[0].src = "JS.js";
</script>
</head>
<body onLoad="javascript:Function2();">
<script type="text/javascript">
Function1();
</script>
</body>
</html>
이 어떻게 (해결 방법 1을 사용하지 않고)이 문제를 해결 할 수 ?
: 여기 테스트 나는이 몸의 끝 부분에 도착하기 전에 JS를 읽을 완료합니다 : HTTP : //lucaghio.webege. co.kr/Prova5/2/2.html – cassiodoroVicinetti