htmldiff.net icon indicating copy to clipboard operation
htmldiff.net copied to clipboard

'tr' and 'td' tags treated as simple text and omitted if next row is deleted

Open oscamp08 opened this issue 8 years ago • 0 comments

If you change the text in a table and delete the next row, the match algorithm in some way cannot detect the changes properly and will cause the <tr><td> to be treated as simple text. The result will be that 'from one place to another' (in example) will be mixed with tags and inserted after, causing the words to be split across the cells

Here you can validate 1 case:

string oldText = @"<table cellpadding='0' cellspacing='0'><tr><td>Some sample text2</td<td>Some sample value2</td></tr><tr><td>Data 1 (this row will be removed)</td><td>Data 2</td></tr> </table>'

string newText = @"<table cellpadding='0' cellspacing='0'><tr><td>text totally changed, words are passing</td><td>from one place to another</td></tr></table>"

oscamp08 avatar Jan 24 '17 15:01 oscamp08