티스토리 뷰
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>필터</title>
<script type="text/javascript" src="js/jquery-1.8.3.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$.ajax({
type:"post",
url:"http://localhost:8080/JqueryTest/TEST_1.js",
dataType:"json",
success:function(ajaxResult){
alert(ajaxResult);
alert(ajaxResult[0].name +"///"+ajaxResult[0].age);
alert(ajaxResult[1].name +"///"+ajaxResult[1].age);
}, error: function(xhr,status,error){
alert(error);
}
});
});
</script>
</head>
<body>
<form id="form" name="form">
<table>
<tr>
<td><span id="ajaxResult"></span></td>
</tr>
</table>
<table>
<tr>
<td> <p>JSON</p>
$(document).ready(function(){ </br>
$.ajax({ </br>
type:"post", //사용할 메소드</br>
url:"http://localhost:8080/JqueryTest/TEST_1.js", //요청 URL</br>
dataType:"json", //응답의 결과로 반환되는 데이터종류 </br>
success:function(ajaxResult){ </br>
alert(ajaxResult); </br>
alert(ajaxResult[0].name +"///"+ajaxResult[0].age); </br>
alert(ajaxResult[1].name +"///"+ajaxResult[1].age); </br>
},</br>
error: function(xhr,status,error){ </br>
alert(error); </br>
} </br>
}); </br>
}); </br>
</td>
</tr>
</table>
</form>
<table id="table2">
<tr>
<td><a href="index.jsp">돌아가기</a></td>
</tr>
<tr>
<td><a href="jquery_test10_1.jsp">json</a></td>
</tr>
</table>
</body>
</html>
- Total
- Today
- Yesterday
- 담양 죽녹원
- 임자도
- 인천여행
- 파주여행
- 오라클
- 맛집
- 이클립스
- 밀리세컨드
- oracle
- 부천역
- 대관령양떼목장
- 인스타그램
- PPTX
- pdf ms워드 변환
- 테라로사
- 가평팬션
- ora-01940
- 가평여행
- 정동지
- 인천
- 산외한우마을
- 제주도여행
- 토드
- 덤프
- jdk
- 보성녹차밭
- java api
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |