JavaScript 44

210923_event+button+confirm+prompt

DOCTYPE html> Insert title here #out{ position: absolute; left: 20px; top: 100px; background: #ffc; padding: 10 10 10 10; width: 300px; height: 100px; border: 1px solid gray; } function test1(a) { alert(a+100); } function test2(str) { alert("문자열["+str+"]을 받았어요!"); } function test3() { var a=confirm('데이터를 추가할까요?'); /* true값이 1, false는 2 */ if (a==1) out.innerHTML='추가했습니다'; else out.innerHTML='취소했..

JavaScript 2021.09.23