You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@royale.apache.org by GitBox <gi...@apache.org> on 2018/02/20 08:41:39 UTC

[GitHub] Harbs opened a new issue #22: Unable to parse valid XML with CDATA

Harbs opened a new issue #22: Unable to parse valid XML with CDATA
URL: https://github.com/apache/royale-compiler/issues/22
 
 
   The following code:
   ````
   var content:XML =
   <root>
   	<content><![CDATA[<?xpacket begin="" id="W5M0MpCehiHzreSzNTczkc9d"?>
   <x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 5.3-c011 66.145661, 2012/02/06-14:56:27        ">
      <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
         <rdf:Description rdf:about=""/>
      </rdf:RDF>
   </x:xmpmeta>
   <?xpacket end="r"?>]]></content>
   </root>;
   ````
   
   Produces an error in the compiler:
   ````
   Syntax error: 'content' tag (or tag before this tag, or non-tag inside this tag) is unclosed or tag not allowed here.
       [mxmlc]
       [mxmlc] <?xpacket end="r"?>]]></content>
       [mxmlc]                       ^
    ````
   Removing CDATA makes the error go away:
   ````
   var content:XML =
   <root>
   	<content><?xpacket begin="" id="W5M0MpCehiHzreSzNTczkc9d"?>
   <x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 5.3-c011 66.145661, 2012/02/06-14:56:27        ">
      <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
         <rdf:Description rdf:about=""/>
      </rdf:RDF>
   </x:xmpmeta>
   <?xpacket end="r"?></content>
   </root>;
   ````

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services