XSLT for each letter in a string

前端 未结 6 1098
一向
一向 2021-01-11 17:44

I\'m writing an XSLT transformation (for XSL-FO), and need to repeat something for each letter in a string value, for example:

If string is stored in MyData/My

6条回答
  •  萌比男神i
    2021-01-11 18:44

    Good question, +1.

    This is what the template/function str-map from FXSL is for:

    
       
    
       
    
       
    
       
    
       
         
    
         
           
           
         
       
    
        
          
    
          
        
    
    

    when this transformation is applied on any XML document (not used), the wanted result is produced:

    sssooommmeeettthhhiiinnnggg
    

提交回复
热议问题