How to implement Carriage return in XSLT

后端 未结 10 1325
甜味超标
甜味超标 2020-12-28 15:18

I want to implement carriage return within xslt. The problem is I have a varible: Step 1 = Value 1 breaktag Step 2 = Value 2 as a string and would like to appear as

10条回答
  •  独厮守ぢ
    2020-12-28 16:17

    The cleanest way I've found is to insert !ENTITY declarations at the top of the stylesheet for newline, tab, and other common text constructs. When having to insert a slew of formatting elements into your output this makes the transform sheet look much cleaner.

    For example:

    
    
    ">
    ]>
    
    
      
        &nl;&nl;
        
      
    

    ...

提交回复
热议问题