html table filter, array and ignore html

I am using the following JavaScript to filter table contents (all columns), but I am facing a few issues: 1- I want to add an array for letters so it shows some words with "French accent marks" (e = ë, è, é, ê) – (c = ç).. etc. 2- How to ignore inner html tags,… Read More html table filter, array and ignore html

How to make td (table cell) height to be the same as an < a> (link element) height?

I have created a simple example https://jsfiddle.net/9usfctbp/ that contains the issue. There is a code from fiddle: <table> <tr> <td> <a href="#"> Link </a> </td> </tr> </table> a { display: block; font-size: 16px; line-height: 16px; } Expected result: td has height 16px the same as a link. Actual result: td has height 18px that is… Read More How to make td (table cell) height to be the same as an < a> (link element) height?

Python read html table from confluence and print each row as list

I’d like to parse confuence page ,read table and create list for each row. My Table looks like My code x = confluence.get_page_by_id(p_id,expand="body.storage") soup = BeautifulSoup(x["body"]["storage"]["value"], ‘html.parser’) for tables in soup.select("table tr"): data = [item.get_text() for item in tables.select("td")] print(data) But problem is, second column becuase of the new lines output of the code [‘Karnataka’,’Bangalore’,’BangaloreMysoreTumkur’]… Read More Python read html table from confluence and print each row as list

How to lay an image over an image in table cell

I’m trying to lay an image on top of an image in a table cell (if you click on it). <table> <tr> <td style="background-color:Gray;"><a id="firstcell" onclick="addImage"><img scr="snowman.png"></a></td> </tr> … </table> Here is the addImage function: function showMoves(fig_name,pos) { var image = document.createElement("img"); var imageParent = document.getElementById("firstcell"); image.src = "circle.png"; image.style.position = "absolute"; imageParent.appendChild(image); } I… Read More How to lay an image over an image in table cell

Why all <tr> go in <thead> after calling a createTHead

I have a question regarding this code: const table = document.createElement("TABLE"); const thead = table.createTHead(); const tr = thead.insertRow(); const th1 = tr.insertCell(); th1.textContent = "header1"; const th2 = tr.insertCell(); th2.textContent = "header2"; const tr2 = table.insertRow(); const td1= tr2.insertCell(); td1.textContent = "field1"; const td2 = tr2.insertCell(); td2.textContent = "field2"; document.getElementById("main").appendChild(table); All rows insert in… Read More Why all <tr> go in <thead> after calling a createTHead

Browser adds a mysterious <td></td> at the end of one table row

This is my simplified code: <head> <style> table { border-collapse: collapse; width: 100%;} table td { padding-right: 15px; padding-left: 15 px; background-color: beige; border: none; } table td:first-child { text-align: left; } table tr td { vertical-align: middle; } table#legendtable td { font-size: x-small; padding: none; text-align: center; width: 5%; border: 1px solid black; }… Read More Browser adds a mysterious <td></td> at the end of one table row