Exporting HTML Table to Excel via Page Method

I have the following code on the client side for retrieving data from the HTML Table and then send it to the server through the page method:function dtExportToCSV(dataTable) var elements = dtDataToJSON(dataTable);...