Export your <table>
to CSV or XLS, within your browser (or another external script).
http://snack-x.github.io/excelexport.js/
<table id="table">
<tr><th>Column 1</th><th>Column 2</th></tr>
<tr><td>100</td><td>200</td></tr>
<tr><td>1000</td><td>2000</td></tr>
</table>
table_id
: id of table element (e.g. "table")
Constructs excelExport
object.
Parses table for CSV. colspan
is supported. rowspan
is not supported.
Returns raw CSV data as string.
Returns data URI for CSV.
server
: URL of external scriptfilename
: Filename of downloaded file
Downloads CSV file via external script. It will send POST request to server
. Sample script is included (download.php
).
sheet_name
: Name of excel sheet
Parses table for XLS.
Returns raw XLS data as string.
Returns data URI for XLS.
server
: URL of external scriptfilename
: Downloaded file's name
Downloads XLS file via external script.