티스토리 뷰

웹프로그래밍/js

jQuery.postJSON ?

공허공자 2012. 1. 3. 13:47
jQuery.getJSON 은 GET 방식으로 전송한다.
그러면 post 방식으로 전송하고 json 으로 응답받으려면?
$.post(url, data, function(jsonResponse) {
    // Do something with  jsonResponse
}, 'json');

[출처] http://abeautifulsite.net/blog/2008/05/postjson-for-jquery/

댓글
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
«   2025/09   »
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
글 보관함