Should be more like this
function AddSubscriptionToList(PublicationID, EmployeeID) {
var pubid = { "PublicationID": PublicationID, "EmployeeID": EmployeeID };
$.ajax({
url: '@Url.Action("AddSubscriptionToDB", "Home")',
cache: false,
type: 'POST',
dataType: 'json',
contentType: 'application/json; charset=utf-8',
data: JSON.stringify(pubid),
error: function (xhr, status, error) {
alert(xhr.responseText);
},
success: function (data) {
loadPublicationList();
}
});
}