Adding a new line/break tag in XML

xml

Solution

The solution to this question is:

<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/xsl" href="dummy.xsl"?>
  <item>
     <summary>
        <![CDATA[Tootsie roll tiramisu macaroon wafer carrot cake. <br />      
                 Danish topping sugar plum tart bonbon caramels cake.]]>
     </summary>
  </item>

by adding the `<br />` inside the the `<![CDATA]]>` this allows the line to break, thus creating a new line!

Problem

I have been trying to add a new line/break to code within XML and have been unsuccessful. I have tried so far: ``` &lt;br /&gt; &lt;br&gt; &#xA; ``` Here is a sample of the code I am working with. I included "`&#xA;`" to show where the break is located within the code. ``` <?xml version="1.0" encoding="utf-8"?> <?xml-stylesheet type="text/xsl" href="dummy.xsl"?> <item> <summary>Tootsie roll tiramisu macaroon wafer carrot cake. &#xA; Danish topping sugar plum tart bonbon caramels cake. </summary> </item> ```

Original source

Related problems