Here is my problem. I have a web method in C# that is called via ajax. I can see that the browser does 1 post but after some time the method seems to run again without any request sent from the browser.
This only happens with Firefox and with SSL enabled on the web box. There is no looping in the webmethod.
If we turn SSL off then the application works as expected.
I know the web method is being call multiple times but it doesn't seem it's coming from the browser.
If anyone has any idea what could be causing this please could they let me know.
Thank you.
Ajax request
$.ajax({
type: "post",
contentType: "application/json",
url: "../_background/Data.aspx/CreateVM",
data: JSON.stringify(param),
dataType: 'json',
success: function (result) {
var s = $.parseJSON(result.d);
if (s.success) {
o.end_task(true, s.response);
}
else {
parent.commonObj.evErrorToggle(s.error_message);
o.end_task(false, s.response);
}
o.rolling_resource_remove(s.response);
o.populate_resource_usage();
}
});
you can stop the next post by
var fired = false;
if ( ! fired ) {
$.ajax({
type: "post",
contentType: "application/json",
url: "../_background/Data.aspx/CreateVM",
data: JSON.stringify(param),
dataType: 'json',
success: function (result) {
--------------> fired = true;
var s = $.parseJSON(result.d);
if (s.success) {
o.end_task(true, s.response);
}
else {
parent.commonObj.evErrorToggle(s.error_message);
o.end_task(false, s.response);
}
o.rolling_resource_remove(s.response);
o.populate_resource_usage();
}
});
}