How to compare against multiple strings in xslt

后端 未结 6 451
滥情空心
滥情空心 2020-12-10 12:45

For comparing an xml string value against multiple strings, I am doing the following.



        
6条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-10 13:12

    Three ways of doing this:

    1. Use a pipe (or other appropriate character) delimited string

    ...

     
         
     
    

    .2. Test against an externally passed parameter. If the parameter is not externally set, and we are using XSLT 1.0, the xxx:node-set() extension function needs to be used to convert it to normal node-set, before accessing its children

    
     
     
    
     
     
      John
      Steve
      Mark
     
    
     
      
         
        
     
    
    

    .3. In XSLT 2.0 compare against a sequence of strings

     
         
     
    

提交回复
热议问题