nicolaskruchten / jupyter_pivottablejs

Drag’n’drop Pivot Tables and Charts for Jupyter/IPython Notebook, care of PivotTable.js
http://nicolas.kruchten.com/content/2015/09/jupyter_pivottablejs/
Other
687 stars 88 forks source link

Enable hyperlinks for one column / element html rendering #63

Closed vkresch closed 3 years ago

vkresch commented 3 years ago

Is it possible to add hyperlinks to elements of a specific column? There was already a similar dicussion here. Which is solved in javascript and is also kind of a workaround.

It would be nice if html rendering for all elements would be possible. Meaning if I have a column with this value:

<a href="google.com">Link to Google</a> 

This then would be a real link. Please let me know if there would be another workaround for that issue. For example a post-processing of the pivottable.html file or something. Thanks in advance for all answers!

vkresch commented 3 years ago

This answer helped me in showing hyperlinks in the table. I needed also to replace

$.csv.toArrays($("#output").text() 

with

$.csv.toArrays($("#output").html().replace(/"/g, "'"))

I had also an issue with double quotes but I solved it by replacing it with single quotes. I hope this is helpful for other developers.