In the past two days, we have been working on XML + XSLT output standardization, that is, the output of the XHTML StandardCode
The namespace xmlns ="Http://www.w3.org/1999/xhtml"Is the key to correctly outputting the XHTML Standard
If this namespace is not available, the output document tag will automatically remove the ending/The symbol <meta xxx/> is changed to <meta XXX>
There are two alternative methods:
1. Define an xhtmlwrite class and rewrite the writeendelement () method to disable the method;
2. Add the above space to the template file XLST ~ .
For the first method, the result is that all <XSL: Output Methods in the XSLT template are ineffective, and the output format looks different from that on w3.
The second method is to automatically merge the labels of empty content in the output result, that is, the result <div> </div> is changed to <DIV/>, which is quite uncomfortable. the current solution is to add<XSL: Text> </XSL: Text>Or add a tag at the end of the tag that you do not want to close.XML: Space = "preserve">And wrap the ending label.
I don't know what Microsoft is thinking.XsltransformChangeXslcompiledtransformThe result is such a thing ~
If any hero has a better solution, please remind me.