I have what I hope is a successful post to my client's json API (in that it correctly sends data) but I'm having a very hard time grabbing that data and using it as a variable to update my site...
$.post(takeurl, function(data) {
var newPrice = json.data.newPrice;
alert('hi' );
}, "json");
$(this).parents("tr").find(".large-detail").html(newPrice);
return false;
});
Basically, in this example I want to update large-detail with the newPrice data from my API call, which is returned like this:
{"data":{"newPrice":80,"lockedInPrice":47},"errors":[],"success":true,"code":200}
Ideas? I just can't get newPrice through. I'm hoping I made a stupid syntax error, even if it'll make me feel like an idiot.