클릭 시 여러 JavaScript 함수를 호출하려면 아래와 같이 세미콜론을 사용하십시오. -
onclick="Display1();Display2()"
예시
라이브 데모
<html>
<head>
<script>
function Display1() {
document.write ("Hello there!");
}
function Display2() {
document.write ("Hello World!");
}
</script>
</head>
<body>
<p>Click the following button to call the function</p>
<form>
<input type = "button" onclick = "Display1(); Display2()" value = "Result">
</form>
</body>
</html>