xslt: substring-before

后端 未结 3 580
春和景丽
春和景丽 2020-12-18 23:44

I have the folowing xml code:

14 3
12
7 3 78         


        
3条回答
  •  自闭症患者
    2020-12-18 23:59

    You can use functx:substring-before-if-contains

    The functx:substring-before-if-contains function performs substring-before, returning the entire string if it does not contain the delimiter. It differs from the built-in fn:substring-before function, which returns a zero-length string if the delimiter is not found.

    Looking at the source code, it's implemented as follows:

    
    
    
    
    
    

提交回复
热议问题