EditableGrid is an open source Javascript library aimed at turning HTML tables into advanced editable components. It focuses on simplicity: only a few lines of code are required to get your first table up and running.
it all works fine. However, it seems to work fine only because of the way the sample data was set up. In particular, part of grid.json looks like this --
processJSON() allows you to specify data either as a list of columns or as an associative array. Looks like the sample data was given this way so we can see both methods. (Very nice.)
However, the list of columns only works as long as an associative array had been processed previously.
If the first data point processed is a list of columns, you get a
"Uncaught ReferenceError: cellValues is not defined"
error.
The fix seems quite simple. In editablegrid.js, add this line --
var cellValues = {};
before this line
// row values can be given as an array (same order as columns) or as an object (associative array)^M
So, looking at this demo --
http://www.editablegrid.net/editablegrid/examples/json/index.html
it all works fine. However, it seems to work fine only because of the way the sample data was set up. In particular, part of grid.json looks like this --
processJSON() allows you to specify data either as a list of columns or as an associative array. Looks like the sample data was given this way so we can see both methods. (Very nice.)
However, the list of columns only works as long as an associative array had been processed previously.
If the first data point processed is a list of columns, you get a
"Uncaught ReferenceError: cellValues is not defined"
error.
The fix seems quite simple. In editablegrid.js, add this line --
before this line