Client-Side Ajax Table Not Rendering
Client-Side Ajax Table Not Rendering
This is driving me crazy. I'm trying to populate a simple table with json from a MVC controller.
Name |
---|
$(document).ready(function() {
var table = $('#programListTable').DataTable({
ajax: {
url: "/library/GetProgramData?id=227"
},
columns: [{
data: "Name"
}]
});
});
JSON (shortened) returned from '/library/GetProgramData?id=227'
{"data":[{"ParentProgramID":1179265,"Name":"12 News Daybreak"},{"ParentProgramID":377424,"Name":"12 News KBMT at 10pm"},{"ParentProgramID":377429,"Name":"12 News KBMT at 5pm"}]}
The paging bar shows: Showing 0 to 0 of 0 entries (filtered from 76 total entries)
I know the data is being returned from the server but nothing is rendered. What am I missing?
Answers
Sorry...here's the HTML.