https://bugs.documentfoundation.org/show_bug.cgi?id=170063
Bug ID: 170063
Summary: html export inappropriately colors field values
Product: LibreOffice
Version: 26.8.0.0 alpha0+ master
Hardware: All
OS: Linux (All)
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: filters and storage
Assignee: [email protected]
Reporter: [email protected]
Created attachment 204735
--> https://bugs.documentfoundation.org/attachment.cgi?id=204735&action=edit
fielddemo.odt (see steps to reproduce)
When a document is saved as .html, any "field" references show with a dark
background when the .html is viewed in a browser (similar to how they look in
LO when editing).
The generated html includes custom tags which allow LO to recognize field
references if the .html file is re-imported later (e.g. for more editing). The
dark background is unnecessary, and I think it causes an unintended direct
character format to be introduced when the .html is re-read.
The generated html looks like this:
<span style="background: #c0c0c0">
<sdfield type=DATETIME sdnum="1033;1033;MMMM D, YYYY">
December 19, 2025
</sdfield>
</span>
STEPS TO REPRODUCE:
1. Create a Writer document with a field reference, for example
Type "Today's date is" then Insert->Field->Date(Variagble)
-OR-
Load the attached "fielddemo.odt"
2. File->SaveAs, set the file type to "HTML DOcument (Writer)(.html); click
Save
3. Examine the resulting .html file
4. firefox file.html # view the result in a browser
RESULTS: The field value has a dark background when the .html file is
deployed.
EXPECTED RESULTS: No background color (unless the user explicitly formatted the
text with a background color in LO).
--
You are receiving this mail because:
You are the assignee for the bug.