I'm transforming an XML document to an HTML one. I'd like to remove every instance of a processing instruction from the source doc.
I've figured out how to remove specific processing instructions via <xsl:template match="processing-instruction('processing_instruction_name')"/>
but the processing instructions I'm dealing with vary from document to document.
I've tried variations of * for the processing_instruction_name, but my XSL engine keeps throwing parsing errors. Is what I want to do possible? If so, how do I do it?
Any help is appreciated!
You just need to create an empty template to match all processing-instruction()
nodes in your stylesheet:
<xsl:template match="//processing-instruction()" />
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With