Search code examples
jqueryjquery-post

Does $.post means partial postback?


When we use $.post, I used breakpoint and found that my Page_Load event fires again. So what is the use of $.post, is this a partial postback?

I am confused, if Page_Load event fires in both cases (server side call, $.post) then what are the advantages of $.post?


Solution

  • I believe you are using $.post to access the same page, which completely defeats the purpose of using ajax. You should $.post either to a webservice (or another page) that directly handles your request.

    Also, to address your main question, $.post is not technically a postback at all. It is an xmlHttpRequest (ajax). The term "partial postback" generally refers to ajax.