As previously announced via banners and our newsletters, support is no longer available through this platform.

For easier navigation, you can still click on "Submit a Ticket" here, choose the appropriate category, and you'll be redirected to the correct support channel for your plugin.

You can still access your previous tickets and browse public tickets, but please note that responding to tickets is no longer possible.

Paid customers: Please log in to your store account for support.

Pre-purchase questions: Use the support widget in the bottom-right corner of our websites:
https://wpamelia.com
https://wpdatatables.com
https://wpreportbuilder.com

Okay
  Public Ticket #3003793
Displaying a returned csv or json table from an external API call via wbDataTables
Closed

Comments

  • Mohammed started the conversation

    I have a short code that calls an external API via a GET call and returns a csv or json formatted table response. How I can capture that data and override the data only (not the table headers) in an exiting wbDataTable and display the refreshed table via wbDataTable Short Code?

  •  1,896
    Miloš replied

    Hi, Mohammed

    Thanks for showing interest in wpDataTables

    - Sorry if I didn't understand everything correctly, please correct me if that's the case.

    Basically, you can get a CSV or JSON formatted response as the result, and you would like to see how it can be implemented into an existing wpDataTable?

    -

    This depends on what type of table you would be using to update it.

    If you link a table to the source data, during table creation, such as JSON or CSV, and if you update/edit the source, the output table would stay synchronized/linked with it.

    1. If you use JSON format, important note :

    When working with JSON format please note: Currently, wpDataTables accepts this, and only this, format of JSON (see example): a one-level array of same-structured objects where each object will be parsed as a row, and each field inside of the object as a cell. If your software does not return this format, you would need to prepare, as an example some PHP adapter to return one of the formats that wpDataTables would accept.

    More details here.

    2. Regarding linking a table to a CSV file, please check out this documentation with an example.

    -

    Let me know how that sounds, and if you have further questions.

    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    Try our FREE mapping plugin! MapSVG - easy Google maps, interactive SVG maps and floor plans, choropleth maps and much more - https://wordpress.org/plugins/mapsvg-lite-interactive-vector-maps/

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables