All Projects → onizet → Html2openxml

onizet / Html2openxml

Licence: mit
Html2OpenXml is a small .Net library that convert simple or advanced HTML to plain OpenXml components. This program has started in 2009, initially to convert user's comments from SharePoint to Word.

Projects that are alternatives of or similar to Html2openxml

Markdownslides
MarkdownSlides is a Reveal.js and PDF slides generator from MARKDOWN files, that also generate HTML, EPUB and DOCX documents. The idea is that from a same MARKDOWN file we can get slides and books without worrying about style, just worrying about content.
Stars: ✭ 121 (-14.79%)
Mutual labels:  docx
Steamtools
🛠「Steam++」是一个开源跨平台的多功能Steam工具箱。
Stars: ✭ 4,458 (+3039.44%)
Mutual labels:  dotnetcore
Avalonia
A cross platform XAML framework for .NET
Stars: ✭ 12,588 (+8764.79%)
Mutual labels:  dotnetcore
Dotnetbook
.NET Platform Architecture book (English, Chinese, Russian)
Stars: ✭ 1,763 (+1141.55%)
Mutual labels:  dotnetcore
Grandnode
Open source, headless, multi-tenant eCommerce platform built with .NET Core, MongoDB, AWS DocumentDB, Azure CosmosDB, Vue.js.
Stars: ✭ 1,768 (+1145.07%)
Mutual labels:  dotnetcore
Ueditor.core
百度UEditor后端服务.Net Core 2.0 版本,简单易用,文档齐全,速来尝试,还支持.Net Framework~
Stars: ✭ 133 (-6.34%)
Mutual labels:  dotnetcore
Nsubstitute
A friendly substitute for .NET mocking libraries.
Stars: ✭ 1,646 (+1059.15%)
Mutual labels:  dotnetcore
Docxtractr
✂️ Extract Tables from Microsoft Word Documents with R
Stars: ✭ 139 (-2.11%)
Mutual labels:  docx
Eventflow.example
DDD+CQRS+Event-sourcing examples using EventFlow following CQRS-ES architecture. It is configured with RabbitMQ, MongoDB(Snapshot store), PostgreSQL(Read store), EventStore(GES). It's targeted to .Net Core 2.2 and include docker compose file.
Stars: ✭ 131 (-7.75%)
Mutual labels:  dotnetcore
Dotnetlabs
.NET Labs -- Show Me the Tips and Tricks and Code
Stars: ✭ 135 (-4.93%)
Mutual labels:  dotnetcore
Signalw
Even simpler and faster real-time web for ASP.NET Core.
Stars: ✭ 125 (-11.97%)
Mutual labels:  dotnetcore
Etherpad Lite
Etherpad: A modern really-real-time collaborative document editor.
Stars: ✭ 11,937 (+8306.34%)
Mutual labels:  docx
Net Core Docx Html To Pdf Converter
.NET Core library to create custom reports based on Word docx or HTML documents and convert to PDF
Stars: ✭ 133 (-6.34%)
Mutual labels:  docx
Docx
Easily generate .docx files with JS/TS with a nice declarative API. Works for Node and on the Browser.
Stars: ✭ 2,150 (+1414.08%)
Mutual labels:  docx
Jobwanted
找工作 (喜欢就赏颗星星呗!) 【演示地址】:http://job.haojima.net
Stars: ✭ 136 (-4.23%)
Mutual labels:  dotnetcore
Sio.core
✔ [ SIOC ] Swastika I/O Core is an all in one platform (e.g CMS, eCommerce, Forum, Q&A, CRM...) ASP.NET Core / Dotnet Core System based on SIOH Framework.
Stars: ✭ 121 (-14.79%)
Mutual labels:  dotnetcore
Wopihost
ASP.NET Core MVC implementation of the WOPI protocol. Enables integration with WOPI clients such as Office Online Server.
Stars: ✭ 132 (-7.04%)
Mutual labels:  dotnetcore
Coravel
Near-zero config .NET Core micro-framework that makes advanced application features like Task Scheduling, Caching, Queuing, Event Broadcasting, and more a breeze!
Stars: ✭ 1,989 (+1300.7%)
Mutual labels:  dotnetcore
Nlayerappv3
Domain Driven Design (DDD) N-LayeredArchitecture with .Net Core 2
Stars: ✭ 138 (-2.82%)
Mutual labels:  dotnetcore
Hrconvert2
A self-hosted, drag-and-drop, & nosql file conversion server that supports 62x file formats.
Stars: ✭ 132 (-7.04%)
Mutual labels:  docx

Latest version License MIT NuGet codecov.io

netstandard1.3 netstandard2.0 net46

What is Html2OpenXml?

Html2OpenXml is a small .Net library that convert simple or advanced HTML to plain OpenXml components. This program has started in 2009, initially to convert user's comments from SharePoint to Word.

This library supports both .Net Core (netstandard1.3) and .Net Framework 4.6.

Depends on DocumentFormat.OpenXml.

See Also

Supported Html tags

Refer to w3schools’ tag list to see their meaning

  • <a>
  • <h1-h6>
  • <abbr> and <acronym>
  • <b>, <i>, <u>, <s>, <del>, <ins>, <em>, <strike>, <strong>
  • <br> and <hr>
  • <img>, <figcaption>
  • <table>, <td>, <tr>, <th>, <tbody>, <thead>, <tfoot> and <caption>
  • <cite>
  • <div>, <span>, <font> and <p>
  • <pre>
  • <sub> and <sup>
  • <ul>, <ol> and <li>
  • <dd> and <dt>
  • <q> and <blockquote> (since 1.5)
  • <article>, <aside>, <section> are considered like <div>

Javascript (<script>), CSS <style>, <meta> and other not supported tags does not generate an error but are ignored.

Tolerance for bad formed HTML

The parsing of the Html is done using a custom Regex-based enumerator. These are supported:

samples
Ignore case <span>Some text<SPAN>
Missing closing tag or invalid tag position <i>Here<b> is </i> some</b> bad formed html.
no need to be XHTML compliant Both <br> and <br/> are valid
Color red, #ff0000, #f00, rgb(255,0,0,.5), hsl(0, 100%, 50%) are all the red color
Attributes <table id=table1> or <table id="table1">

Acknowledgements

Thank you to all contributors that share their bug fixes: scwebgroup, ddforge, daviderapicavoli, worstenbrood, jodybullen, BenBurns, OleK, scarhand, imagremlin, antgraf, mdeclercq, pauldbentley, xjpmauricio, jairoXXX, giorand, bostjanKlemenc, AaronLS, taishmanov. And thanks to David Podhola for the Nuget package.

Logo provided with the permission of Enhanced Labs Design Studio.

Support

This project is open source and I do my best to support it in my spare time. I'm always happy to receive Pull Request and grateful for the time you have taken If you have questions, don't hesitate to get in touch with me!

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].