Convert HTML Table To CSV – table2csv

Category: Javascript , Table | October 9, 2020
Views Total:1,661 views
Official Page:Go to website
Last Update:October 9, 2020


Convert HTML Table To CSV – table2csv


table2csv is a vanilla JavaScript Table To CSV converter that reads and saves tabular data as a CSV file for further use.

See Also:

How to use it:

1. Insert the table2csv.min.js file into the HTML page.

<script src="table2csv.min.js"></script>

2. Assign a unique ID to your HTML table.

<table id="example">

3. Create a converter button and determine the selector of the target HTML table using the data-table attribute:

<button onclick="table2csv(this,1)" 
        Download The Table

You Might Be Interested In:

Leave a Reply