< XML and TextFlowUtil.importFromXML
Hi,
I am using flex. But it is about an XML importation so maybe it is the right place to post it (I previously tried on the Flex forum without success).
I want to display some Xml Files. Here I reproduce my code:
* my main file
<?xml version="1.0" encoding="utf-8" ?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
>
<fx:Script>
<![CDATA[
import spark.utils.TextFlowUtil;
XML.ignoreWhitespace = false;
]]>
</fx:Script>
<fx:Declarations>
<fx:XML id="xmlFile" source="testxml.xml"/>
</fx:Declarations>
<s:Panel>
<s:RichEditableText id="code2" editable="false"
textFlow="{TextFlowUtil.importFromXML(xmlFile)}"/>
</s:Panel>
</s:Application>
* testxml.xml
<?xml version="1.0" encoding="utf-8"?>
<TextFlow xmlns="http://ns.adobe.com/textLayout/2008"
whiteSpaceCollapse="preserve">
<span>Coucou</span> <
</TextFlow>
If testxml.xml does not contain < (or &rt;), this works fine, but as soon as I put this caracters, whereas the compilation works, the application does not appear in my brownser (I use Linux, I don't have any error message).
Thanks for your help.
