XSLT: copy object xml multiple times while incrementing attribute and value

后端 未结 2 969
你的背包
你的背包 2021-01-07 01:40

I have a xml as below that I\'d like to copy n times while incrementing one of its element and one of its attribute.

XML input:



        
2条回答
  •  悲哀的现实
    2021-01-07 02:05

    This transformation:

    
         
         
    
         
    
         
          
          
           
             
           
          
         
    
         
             
                 
                 
             
         
    
         
             
             
    
             
                 
                 
                     
                     
                     
                 
                 
                     
    
                     
                     
                     
                     
    
                     
                     
                     
                     
                 
                 
             
         
    
         
             
    
             
                 
                 
                  
                 
                 
                 
                 
              
         
    
         
              
                
                  
                
         
    
    

    when applied on the provided XML document:

    John 1

    produces the wanted results:

    John 1 John 2

提交回复
热议问题