<!DOCTYPE html>
<html>
<head>
<meta charset = "UTF-8">
<style sypt="text/css">
#loadingMessageContainer
{
width: 300px;
height: 100px;
text-align: center;
background-color: #DDD;
}
</style>
</head>
<body>
<div id = "12-1_XMLHttpRequestExam">
<h3>12-1_XMLHttpRequestExam</h3>
<p>Toncat 콘솔창을 확인하세요.</p>
<script type = "text/javascript" src = "12-1_XMLHttpRequestExam.js"></script>
</div>
<div id ="12-2_getResult">
<h3>12-2_getResult</h3>
<p>잠시만 기다리세요.</p>
<script type="text/javascript" src = "12-2_getResult.js"></script>
<div id = "loadingMessageContainer">Now loading...</div>
</div>
<div id = "12-3_XMLHttpRequestStatus">
<h3>12-3_XMLHttpRequestStatus</h3>
<script type = "text/javascript" src = "12-3_XMLHttpRequestStatus.js"></script>
<script type = "text/javascript">
HTTP.getText('12-2_getResult.jsp',
function(result)
{
var content = document.getElementById("resultContainer");
content.innerHTML = "서버로부터 받은 메세지<br/>" + result;
});
</script>
<p>잠시만 기다리세요.</p>
<div id = "resultContainer" style ="border: 1px solid black; width: 300px; height: 100px">Now loading...</div>
</div>
</body>
</html>
'Programming > JavaScript' 카테고리의 다른 글
[JavaScript] 12-1_XMLHttpRequestExam.jsp (0) | 2016.12.09 |
---|---|
[JavaScript] 12-1_XMLHttpRequestExam.js (0) | 2016.12.09 |
[JavaScript] 11-3_KeyboardEvent.js (0) | 2016.12.08 |
[JavaScript] 11-2_MouseEvent.js (0) | 2016.12.08 |
[JavaScript] 11-1_EventAttr.js (0) | 2016.12.08 |