Is It Possible to Query & Display Multiple JSON Files
Is It Possible to Query & Display Multiple JSON Files
bo1500000
Posts: 1Questions: 1Answers: 0
I have 2 external URL JSON files. The first file has all of the records I need to display on the page for orders, and the second JSON file has the contact info for these orders. Each record in the JSON has a unquie key, which should allow me to combine the results of the query. I have used DataTables before, but only sucussful in displaying one external JSON file at a time. Any help would be greatly appricated.
This discussion has been closed.
Answers
If you don't want to join them in a server script then I suggest using jQuery ajax to retrieve the two JSON files then combine them with a Javascript function. Once combined you can either use
rows.add()
to add them to an already initialized Datatable or usedata
if you want to add while initializing Datatables.Kevin