-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathweek9(8).html
43 lines (35 loc) · 1.15 KB
/
week9(8).html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>예제8-8</title>
</head>
<body>
<table border="1">
<script type="text/javascript">
document.write("<caption>책 주문 입력 내용 </caption>");
document.write("<tr>");
document.write("<th>제목</th>");
document.write("</tr>");
var book1 = "1: 컴퓨터와 IT기술의 이해 [개정판-2판]";
var book2 = "2: 소셜미디어의 이해와 활용";
var book3 = "3: 멀티미디어 배움터 2.0";9
var book_list = book1 + "\n" + book2 + "\n" + book3;
var choice = prompt("책 번호를 입력하세요...\n" + book_list, "1");
if (choice==1)
title=book1;
else if(choice==2)
title=book2;
else if(choice==3)
title=book3;
else{
alert("리스트에 없는 책을 선택하셨습니다.");
title="";
}
document.write("<tr>");
document.write("<td>"+ title + "<td>");
document.write("<tr>");
</script>
</table>
</body>
</html>