On 5/29/23 16:37, Timothy wrote:
Hi Scott,

Just to give some support to my request, the HTML standard
(<https://html.spec.whatwg.org/multipage/syntax.html#start-tags>) says this:
“Then, if the element is one of the void elements, or if the element is a
foreign element, then there may be a single U+002F SOLIDUS character (/), which
on foreign elements marks the start tag as self-closing. On void elements, it
does not mark the start tag as self-closing but instead is unnecessary and has
no effect of any kind. For such void elements, it should be used only with
caution — especially since, if directly preceded by an unquoted attribute value,
it becomes part of the attribute value rather than being discarded by the
parser.”

The things is the ox-html exporter currently tries to (mostly) support XHTML,
which as I understand requires the self-closing slash.

I think what’s really needed is an HTML export implementation that can more
easily support different “modes” of export, but somebody needs to work on that
🙃.

Okay, but when I try to validate my page as XHTML, I get numerous errors that 
would be inconvenient to fix especially since I'm only interested in obtaining 
valid HTML. What I think I'll do is to edit the org-html--build-meta-entry 
function in my ox-html.el file to eliminate the trailing slash. I'll just have 
to remember to do that every time I upgrade Org.

Scott

Reply via email to