Closed docsprodev closed 2 months ago
My test html sample with tables coverts wrong.
<html><head><meta charset="UTF-8"/></head><body><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><table style="cell-spacing:0;cell-padding:0;border-collapse:collapse;width:100%;mso-table-layout-alt:fixed"><tbody columnSizes="310,310"><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr></tbody></table><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><table style="cell-spacing:0;cell-padding:0;border-collapse:collapse;width:100%;mso-table-layout-alt:fixed"><tbody columnSizes="310,310"><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">иыавпывап</p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">ывапывапывап</p></td></tr></tbody></table><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">апапвапр</p><table style="cell-spacing:0;cell-padding:0;border-collapse:collapse;width:100%;mso-table-layout-alt:fixed"><tbody columnSizes="310,310"><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">ввапрварп</p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"><span xml:space="preserve"> </span></p></td></tr><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">вапвапрвапукецукееееее цукецукецукецуке</p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"><span xml:space="preserve"> </span></p></td></tr></tbody></table><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><table style="cell-spacing:0;cell-padding:0;border-collapse:collapse;width:100%;mso-table-layout-alt:fixed"><tbody columnSizes="310,310"><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr></tbody></table><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></body></html>
Only two converters work normal: https://www.onlineconverter.com/html-to-docx https://online-converter.freepdfsolutions.com/
3 converters now, since v3 of this library 😁
My test html sample with tables coverts wrong.
<html><head><meta charset="UTF-8"/></head><body><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><table style="cell-spacing:0;cell-padding:0;border-collapse:collapse;width:100%;mso-table-layout-alt:fixed"><tbody columnSizes="310,310"><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr></tbody></table><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><table style="cell-spacing:0;cell-padding:0;border-collapse:collapse;width:100%;mso-table-layout-alt:fixed"><tbody columnSizes="310,310"><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">иыавпывап</p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">ывапывапывап</p></td></tr></tbody></table><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">апапвапр</p><table style="cell-spacing:0;cell-padding:0;border-collapse:collapse;width:100%;mso-table-layout-alt:fixed"><tbody columnSizes="310,310"><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">ввапрварп</p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"><span xml:space="preserve"> </span></p></td></tr><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0">вапвапрвапукецукееееее цукецукецукецуке</p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"><span xml:space="preserve"> </span></p></td></tr></tbody></table><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p><table style="cell-spacing:0;cell-padding:0;border-collapse:collapse;width:100%;mso-table-layout-alt:fixed"><tbody columnSizes="310,310"><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr><tr><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td><td style="width:310px;height:40px;vertical-align:top;border-width:1px;border-style:solid;border-color:black"><p style="margin-top:10px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></td></tr></tbody></table><p style="margin-top:20px;font-family:'Times New Roman', serif;font-size:14px;line-height:150%;margin-bottom:0"></p></body></html>