I am having a hard time transferring my php array of arrays to a json object.
Array(
[28] => Array(
[0] => Array(
[0] => 1
[1] => 5
)
[1] => Array(
[0] => 1
[1] => 18
)
[424] => Array(
[0] => Array(
[0] => 1
[1] => 5
)
[1] => Array(
[0] => 1
[1] => 18
)
)
)
)
After I json_encode this structure in jQuery I use the .each and get the two arrays but I cant seem to grab the [28] and [424]. Any thoughts?
$.each(data, function(i, val) {
console.log(val); // NAME ??
console.log(data[i][0]); // LIST 1
console.log(data[i][1]); // LIST 2
});
console.log(i)yield?