Pregunta

I'm using SGML Reader to format my html snippets as shown here https://github.com/MindTouch/SGMLReader. Problem is it adds missing tags like in the code. Is there is any way to stop that.

¿Fue útil?

Solución

SgmlReader is intended to convert the source into a valid HTML document. Hence, it will always surround the parsed content with . If you want to remove some of the tags, you can traverse the XML document and either remove the nodes you don't want or, alternatively, copy only the nodes you want to a new XML document.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top