Making this ajax call
var request = $.ajax({
type: 'POST',
url: "http://localhost/thcstore/AJAX/AjaxHawleySS.ashx",
// url: "http://www.myrealsite.com/thcstore/AJAX/AjaxHawleySS.ashx",
data: { Name: $('#Name').val(), ShopName: $('#ShopName').val(), StreetAddress: $('#StreetAddress').val(),
City: $('#City').val(), State: $('#State').val(), ZipCode: $('#ZipCode').val(),
PhoneNumber: $('#PhoneNumber').val(), ProductType: $('#ProductType').val(), Vendor: $('#Vendor').val(), model: $('#model').val(), Issue2: $('#Issue2').val(), email: $('#email').val()
},
success: function (data){
}
});
The call works when i'm running my site on my local machine (local host) but not on my real website. I can navigate to my production site ( www.myrealsite.com/thcstore/AJAX/AjaxHawleySS.ashx) without passing variables and it does not throw any http errors. But if i try to pass any data it gives me an http 500 Internal server error. The ajax call is not coming from the same domain as myrealsite.