Is there an XSLT name-of element?

后端 未结 5 1722
暖寄归人
暖寄归人 2020-11-28 23:47

In XSLT there is the


to get the value of an element, but is there something to select the tag-n

5条回答
  •  陌清茗
    陌清茗 (楼主)
    2020-11-28 23:57

    For those interested, there is no:

    
    

    However you can re-create the tag/element by going:

    
      
    
    

    This is useful in an xslt template that for example handles formatting data values for lots of different elements. When you don't know the name of the element being worked on and you can still output the same element, and modify the value if need be.

提交回复
热议问题