How to detect/track/check postback in javascript(e.g in asp.net Page.isPostBack())? Any suggestion?
If you want to check whether the current page will be a postback if the user clicks on a submit button, you can check for the presence of ViewState:
You can use something like document.getElementById("__VIEWSTATE")
or the jQuery equivalent.
However, if you want to see whether the current page was generated in response to a postback, then you need to insert that data into the page on the server side first.
For example:
function isPostBack() {
return <%= Page.IsPostBack %>;
}