How to avoid all namespace occurrence in output by writing a single statement in XSLT

前端 未结 4 1293
忘了有多久
忘了有多久 2021-02-20 04:09

I wrote \"exclude-result-prefixes\" and even then I see the name space occurrence appearance in output.



        
4条回答
  •  耶瑟儿~
    2021-02-20 04:29

    exclude-result-prefixes just removes the xmlns:foo="" attributes on the root tag of the result. The tags are still bound to the same namespace. Since the tags does not have any matching prefixes, the default namespace is used.

    If you wish to remove the namespaces completely, you could use the following stylesheet:

    
        
    
        
            
                
            
        
    
        
            
                
            
        
    
        
            
                
            
        
    
    

    (source: TEI wiki)

提交回复
热议问题