Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>An really small <a href="http://en.wikipedia.org/wiki/Identity_transform" rel="nofollow">Identity transform</a> should do.<br> The only small "trick" here is to consider the namespaces. Try this:</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:dxl='http://www.lotus.com/dxl' xmlns='http://www.lotus.com/dxl' exclude-result-prefixes='dxl' &gt; &lt;xsl:output method="xml" indent="yes"/&gt; &lt;xsl:template match="@*|node()"&gt; &lt;xsl:copy&gt; &lt;xsl:apply-templates select="@*|node()"/&gt; &lt;/xsl:copy&gt; &lt;/xsl:template&gt; &lt;xsl:template match="dxl:break"&gt; &lt;br&gt; &lt;xsl:apply-templates select="@*|node()"/&gt; &lt;br &gt; &lt;/xsl:template&gt; &lt;/xsl:stylesheet&gt; </code></pre> <p>Which will generate the follwing output:</p> <pre><code>&lt;?xml version="1.0"?&gt; &lt;document xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.lotus.com/dxl" xsi:schemaLocation="http://www.lotus.com/dxl xmlschemas/domino_8_5_3.xsd"&gt; &lt;item name="item1"&gt; &lt;textlist&gt; &lt;text/&gt; &lt;/textlist&gt; &lt;/item&gt; &lt;item name="item2"&gt; &lt;textlist&gt; &lt;text&gt; This&lt;br/&gt;is&lt;br/&gt;a&lt;br/&gt;broken&lt;br/&gt;sentence.&lt;br/&gt; &lt;/text&gt; &lt;/textlist&gt; &lt;/item&gt; &lt;/document&gt; </code></pre> <p><strong>Update</strong> to additional question to ignore "item1" Add following line to the style sheet:</p> <pre><code>&lt;xsl:template match ="dxl:item[@name='item1']" /&gt; </code></pre> <p>Or if only "item2 should be in the output, add a root template:</p> <pre><code>&lt;xsl:template match="/"&gt; &lt;document&gt; &lt;xsl:apply-templates select="*/dxl:item[@name='item2']" /&gt; &lt;/document&gt; &lt;/xsl:template&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload