Hi,
thanks for your question, and sorry for the trouble.
You are totally correct here. The reason why you are having problems with importing this, is that this JSON code is not a simple array. TablePress however requires that format. Unfortunately, a Custom Command for the DataTables JS library will not influence that in any way, as that library has nothing to do with the import.
Now, in the the current developer version of TablePress, I’ve added some code that makes the JSON import more robust, in the sense that more sophisticated JSON code (e.g. encoded objects) can (sometimes) be imported.
You might want to try that, by installing the developer version from http://tablepress.org/download/tablepress-dev.zip
If that does not work, your only chance is to re-format that JSON code before the import.
Regards,
Tobias
Thread Starter
mjif2
(@mjif2)
Tobias, thank you for your quick response! I will download and install the developer version tomorrow morning and report back here.
Hi,
sounds good! I hope this helps!
Regards,
Tobias
Thread Starter
mjif2
(@mjif2)
Thanks, Tobias, but tablepress-dev doesn’t work either. Like Tablepress, it reads the first part of the feed and then errors out on the actual JSON data. I love the functionality of Tablepress but I think I’m going to have to either (a) get our developer to change the structure of the feed or (b) come up with a different method of rendering it.
Regards,
Mary Jo Feeney
Hi,
ah, bummer. Sorry to hear that this didn’t work.
If this is tabular data, method (a) should indeed be the easiest way here, if that’s possible on the API side.
Best wishes,
Tobias