How to create CSV export client-side rows?

How to create CSV export client-side rows?

MazecMazec Posts: 27Questions: 1Answers: 0

Hi, how about via AJAX or a button that sends back to the server via POST information about which lines after instant search / filtering should be generated in CSV? I have the record ID directly in the table listed in the first column.

  1. The server shuts down the table to the client.
  2. As a user, I want to select the records he wants to generate in the CSV via instant search or other filtering.
  3. I want to click on "Generate CSV" and I want to download a CSV in which only the selected records will be directly from me (not all that the server supplied to me in the table).

Thank you so much for the advice and tips.

Replies

  • colincolin Posts: 11,280Questions: 0Answers: 1,927

    There are a few threads discussing how to export data when using serverside, see here and here,

    Colin

  • MazecMazec Posts: 27Questions: 1Answers: 0

    Thanks you.

    I found a complete functional server-side solution.
    http://live.datatables.net/farozutu/1/edit?html,js,output

    But I don't use server-side and I probably don't want to use it.

    Can anyone come up with a solution that will work in client-side without server-side processing?

    Respectively, I need to find out if you can arrange a button to export CSV from the top link in the case of client.side processing, such as here: http://live.datatables.net/

    Do you have any idea how to arrange it?

  • MazecMazec Posts: 27Questions: 1Answers: 0
  • kthorngrenkthorngren Posts: 12,250Questions: 25Answers: 2,867

    See this example for using row-selector options to choose the rows to export. If all your data is client side then you don't want to use the solutions presented. If one the row-selector options doesn't meet your needs then please provide details of how you want to choose the rows to export.

    Kevin

Sign In or Register to comment.