I'm relatively new to jQuery, and I was wondering how would one message be sent to another page and then redirected? I used the ajax function, the redirection works fine, but no variables are written to POST (they are empty)
function linkWO() { $.ajax({ type: "POST", contentType: "application/json; charset=utf-8", url: "LinkTagOut.aspx", dataType: "json", data: "{id=1}", complete: function () { window.location = "LinkTagOut.aspx"; } }); }
in my aspx file
<a href="javascript:void(0);" onclick="return linkWO();"><span>Link</span></a>
jquery redirect post
sarsnake
source share