I am using following ajax call in my .net application. this function execute on click of a button.
$.get("PublishIntermediate.ashx",
{
SiteID: "" + SiteID + "",
PageID: "" + PageIDs + "",
UserID: "" + UserID + "",
Location: "" + "website" + ""
},
function(data)
{
//other code
}
);
return false;
It works fine when PageIDs variable is not too long. But sometimes “PageIDs” variable becomes too long(if user has too many pages) and the ajax call’s length, which I checked from firebug , is too long and the server is returning error. I checked from IIS7 that querystring limit has been exceeded. Is there any other way for performing this task?
GET method has a limit for data
, use POST method in jquery, use $.post(paras) instead $.get(paras).