rainabba / jquery-table2excel

jQuery Plugin to export HTML tabled to Excel Spreadsheet Compatible Files
593 stars 666 forks source link

Exporting 2 decimal places #55

Open panickerr opened 8 years ago

panickerr commented 8 years ago

The plugin while exporting a percentage value with one decimal place automatically suffixes a 0, thus making it 2 decimal places even though its not there in the html. ie if table shows: 94.1% the exported table shows : 94.10%

angadsule commented 8 years ago

I have resolved this issue, shall put the solution tommorow

rainabba commented 8 years ago

Are you sure the plugin is the cause? Unless my code has really diverged from my memory, I think the values are passed in without data-types meaning that Excel is interpreting the data how it sees fit. I'd think that to "fix" the behavior you're seeing, the plugin would have to do data-type management that could be passed to excel; either through auto-detection (very difficult) or explicit data-type declarations being added to each element that needed it and then passed through.

rainabba commented 8 years ago

Looking forward to seeing your solution. Please be sure to pull again before submitting your PR, I just merged some PRs that were outstanding.

angadsule commented 8 years ago

"<!--[if gte mso 9]>"

angadsule commented 8 years ago

i m not able to paste the code..please mail me your email id...on angadsule2006@gmail.com