$.ajax({ url: 'api/product/PostProduct/', cache: false, type: 'POST', contentType: 'application/json; charset=utf-8', data: ko.toJSON(Product), success: function (data) { alert('added'); self.Products.push(data); self.BrandName(""); self.price(""); self.GenericName(""); } }).fail( function (xhr, textStatus, err) { alert('error'); });
url: 'api/product/PostProduct/',
/
url: 'api/product/PostProduct',
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)