0
I have four HTML files and within them have several tables
<table>
.
I am trying to put at the end of each of these files a code to copy only the tables, so that later I can paste in excel and go organizing. I’m not getting the tag copy.
I want to make a fifth file, which copies all tables to paste in excel.
<button onclick="copy()">Copiar</button><br>
<script type="text/javascript">
function copy(){
var text = document.getElementsByTagName("table");
var range = document.createRange();
range.selectNode(table);
window.getSelection().addRange(range);
document.execCommand('copy');
}
</script>
Thank you Devgirl
– Dante