-
can't see the forest for the trees (can't see whats wrong)
im just trying to get CDATA to work and what i see as a perfectly normal piece of code
PHP Code:
<![CDATA[<a href ='http://www.google.co.uk>Google</a>]]
gives me this error
TypeError: Error #1091: XML parser failure: Unterminated CDATA section.
at WelcomePart_fla::MainTimeline/LoadXML()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/onComplete()
i dont see why it would be of any difference but i have applied a stylesheet to my xml within flash.
can anybody see a problem?
thanks
Dan
-
FK'n_dog
missing quote ( ' ) in link
missing closing tag ( > )
<![CDATA[<a href ='http://www.google.co.uk'>Google</a>]]>
Last edited by a_modified_dog; 03-07-2008 at 02:21 PM.
-
hmm.. thanks for that, but now when i load it in to flash it is blank where that link should be.
any ideas why?
-
FK'n_dog
textfield is html enabled, yes ?
PHP Code:
this.createTextField("test",1,10,10,350,35);
test.html = true;
_xml = new XML();
_xml.ignoreWhite = true;
_xml.load("cdata.xml");
/*--cdata.xml--
<?xml version="1.0"?>
<list>
CDATA[<a href ='http://www.google.co.uk'>Google</a>]]>
</list>
*/
_xml.onLoad = function(){
aNode = this.firstChild.firstChild.nodeValue;
test.htmlText = aNode;
};
-
yes bringing it in as myText.htmlText, using a textArea, although im using as3, and importing the xml file which contains the CDATA code.
i am not using this code "test.html = true;" when i tried to bring it in it said
Error #1056: Cannot create property html on fl.controls.TextArea.
and a similar one when i used a dynamic textfield
Last edited by danhodkinson; 03-07-2008 at 06:25 PM.
-
FK'n_dog
in cs3, can you set the html property of the TextArea component
within the Components Parameters panel ? ( as in Flash 8 )
if so, change the xml file to -
PHP Code:
<?xml version="1.0"?>
<list>
<a href ='http://www.google.co.uk'>Google</a>
</list>
and the Flash file to -
Code:
_xml = new XML();
_xml.ignoreWhite = true;
_xml.load("google.xml");
_xml.onLoad = function(){
aNode = this.firstChild.firstChild;
myText.text = aNode;
};
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|