Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

HTML export from LibreOffice Writer

I want to export formatted text from LibreOffice to HTML. By default, it is exported with lot of inline styles.

Is it possible to keep the semantics of the formatting (<p>, <ul>, <h2> and so on), but get rid of the inline styles?

For example, I get <p lang="de-DE" class="western" align="justify" style="margin-bottom: 0in">

What I want is just: <p>

Thanks and regards,

Adriana

like image 979
mikolaskova Avatar asked Aug 16 '26 22:08

mikolaskova


1 Answers

Since years I second your question. I'd like to be able to export some document to a clean html-format, either to process further on or to just use as is.

Today I send an enhancement request to libreoffice to get an export-to for every save-to format. Since html is in the save-as format, it wil end up in the export-to format. With this export to html, we can ask the question for alternate html variants like 'clean html' and optionally create an html-book with one html-page per chapter (html-books).

btw: My reason for export-to for all save-as formats is because I'd like to keep the current format in the editor. after a save-as the editor format is changed to the new format. Then it is accepted to require all formatting to keep the document.

like image 154
CBee Avatar answered Aug 18 '26 22:08

CBee



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!