Create an hierarchical xml form an “flat” xml a like book description

后端 未结 2 1894
眼角桃花
眼角桃花 2021-01-17 05:36

This is a following up question to question to \"Select all of an element between the current element and the next of the current element\". Even If I\'m not sure if creatin

2条回答
  •  时光说笑
    2021-01-17 06:09

    Here my current solution

    
    
        
    
        
            
            
            
            
        
    
        
    
    
        
            
                
                    
                
            
        
    
        
            
                
            
        
    
    
        
            
    
            
                
                    
                    
                
            
    
            
                
    <xsl:value-of select="normalize-space(.)"/>
    end

    It will generate the following output:

    
      
    Section 1 ... ...
    Section 1.1 ...
    Section 1.1.1 ... ...
    Section 1.2 ... ...
    Section 2 ... ...
    Section 2.1 ... ... ...
    Seciton 2.1.1 ...
    Section 2.2 ... ...

提交回复
热议问题