Re: [Flashcoders] Question for XML Style Junkies
??? CDATA tag inside attribute ??? --Keith H-- - Original Message - From: Merrill, Jason [EMAIL PROTECTED] Date: Thursday, March 16, 2006 12:08 pm Subject: [Flashcoders] Question for XML Style Junkies My XML file takes the following form: ?xml version=1.0 encoding=iso-8859-1? home banner imageUrl=media/banner.jpg x=0 y=0/ bar title=Home x=10 y=0 width=750 height=30/ panels panel title=Message x=10 y=10 height=150 width=250 button title=Read Article action=switchTab/ content title=![CDATA[SomebrHTML Text in brhere]] ![CDATA[Lorem Ipsum Paragraph Text Here]] /content /panel panel title=HR Toolbox x=220 y=10 height=150 width=150 button title=Send e-mail action=sendEmail param1=message/ content title=![CDATA[SomebrHTML Text in brhere]] ![CDATA[Lorem Ipsum Paragraph Text Here]] /content /panel panel ...etc. ...etc. /panels /home However, after I load it into Flash, it gets truncated to: ?xml version=1.0 encoding=iso-8859-1? home banner imageUrl=media/banner.jpg x=0 y=0 / bar title=Home x=10 y=0 width=750 height=30/ panels panel title=Message x=10 y=10 height=150 width=250 button title=Read Article action=switchTab/ /panel /panels /home I am assuming the way I am using CDATA tags are throwing it off somehow.For example, I have a CDATA tag inside an attribute value under the Home/Panel/Panel[0]/Title attribute value and this is where it seems to break. Is this bad form and/or causing Flash to choke? If not, what could be causing this? If this is bad XML form, how would you reorganize it to work in Flash? --- FYI - FWIW: I am loading the XML in a standard way: var xmlObject = new XML(); xmlObject.ignoreWhite = true; xmlObject.onLoad = Delegate.create(this, loadSuccess); xmlObject.load(home.xml) and the delegate function just moves the playhead once the file is loaded - when I get to the frame after it's loaded, I do a trace on theXML and see the truncation as described. -- Ideas? Jason Merrill | E-Learning Solutions | icfconsulting.com NOTICE: This message is for the designated recipient only and may contain privileged or confidential information. If you have received it in error, please notify the sender immediately and delete the original. Any other use of this e-mail by you is prohibited. ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Question for XML Style Junkies
I don't know a ton about xml, but I use p and p class=headline and br / and hr / and a href=http://somewhere.com;Somewhere.com website/a tags directly in the xml file amongst text without problems. a separate css file defines the elements. I've never used the CDATA tags or seen the need for them in xml files? - Original Message - From: Merrill, Jason [EMAIL PROTECTED] To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com Sent: Thursday, March 16, 2006 12:08 PM Subject: [Flashcoders] Question for XML Style Junkies My XML file takes the following form: ?xml version=1.0 encoding=iso-8859-1? home banner imageUrl=media/banner.jpg x=0 y=0/ bar title=Home x=10 y=0 width=750 height=30/ panels panel title=Message x=10 y=10 height=150 width=250 button title=Read Article action=switchTab/ content title=![CDATA[SomebrHTML Text in brhere]] ![CDATA[Lorem Ipsum Paragraph Text Here]] /content /panel panel title=HR Toolbox x=220 y=10 height=150 width=150 button title=Send e-mail action=sendEmail param1=message/ content title=![CDATA[SomebrHTML Text in brhere]] ![CDATA[Lorem Ipsum Paragraph Text Here]] /content /panel panel ...etc. ...etc. /panels /home However, after I load it into Flash, it gets truncated to: ?xml version=1.0 encoding=iso-8859-1? home banner imageUrl=media/banner.jpg x=0 y=0 / bar title=Home x=10 y=0 width=750 height=30/ panels panel title=Message x=10 y=10 height=150 width=250 button title=Read Article action=switchTab/ /panel /panels /home I am assuming the way I am using CDATA tags are throwing it off somehow. For example, I have a CDATA tag inside an attribute value under the Home/Panel/Panel[0]/Title attribute value and this is where it seems to break. Is this bad form and/or causing Flash to choke? If not, what could be causing this? If this is bad XML form, how would you reorganize it to work in Flash? --- FYI - FWIW: I am loading the XML in a standard way: var xmlObject = new XML(); xmlObject.ignoreWhite = true; xmlObject.onLoad = Delegate.create(this, loadSuccess); xmlObject.load(home.xml) and the delegate function just moves the playhead once the file is loaded - when I get to the frame after it's loaded, I do a trace on the XML and see the truncation as described. -- Ideas? Jason Merrill | E-Learning Solutions | icfconsulting.com NOTICE: This message is for the designated recipient only and may contain privileged or confidential information. If you have received it in error, please notify the sender immediately and delete the original. Any other use of this e-mail by you is prohibited. ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
RE: [Flashcoders] Question for XML Style Junkies
. I've never used the CDATA tags or seen the need for them in xml files? I don't know what parser you use, but with XPath, I have experienced many problems with HTML inside an XML file when I don't use CDATA. I use CDATA tags and a different XPath method to access it and it works fine. Thanks, Jason Merrill | E-Learning Solutions | icfconsulting.com -Original Message- From: [EMAIL PROTECTED] [mailto:flashcoders- [EMAIL PROTECTED] On Behalf Of Jim Berkey Sent: Thursday, March 16, 2006 1:34 PM To: Flashcoders mailing list Subject: Re: [Flashcoders] Question for XML Style Junkies I don't know a ton about xml, but I use p and p class=headline and br / and hr / and a href=http://somewhere.com;Somewhere.com website/a tags directly in the xml file amongst text without problems. a separate css file defines the elements. I've never used the CDATA tags or seen the need for them in xml files? - Original Message - From: Merrill, Jason [EMAIL PROTECTED] To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com Sent: Thursday, March 16, 2006 12:08 PM Subject: [Flashcoders] Question for XML Style Junkies My XML file takes the following form: ?xml version=1.0 encoding=iso-8859-1? home banner imageUrl=media/banner.jpg x=0 y=0/ bar title=Home x=10 y=0 width=750 height=30/ panels panel title=Message x=10 y=10 height=150 width=250 button title=Read Article action=switchTab/ content title=![CDATA[SomebrHTML Text in brhere]] ![CDATA[Lorem Ipsum Paragraph Text Here]] /content /panel panel title=HR Toolbox x=220 y=10 height=150 width=150 button title=Send e-mail action=sendEmail param1=message/ content title=![CDATA[SomebrHTML Text in brhere]] ![CDATA[Lorem Ipsum Paragraph Text Here]] /content /panel panel ...etc. ...etc. /panels /home However, after I load it into Flash, it gets truncated to: ?xml version=1.0 encoding=iso-8859-1? home banner imageUrl=media/banner.jpg x=0 y=0 / bar title=Home x=10 y=0 width=750 height=30/ panels panel title=Message x=10 y=10 height=150 width=250 button title=Read Article action=switchTab/ /panel /panels /home I am assuming the way I am using CDATA tags are throwing it off somehow. For example, I have a CDATA tag inside an attribute value under the Home/Panel/Panel[0]/Title attribute value and this is where it seems to break. Is this bad form and/or causing Flash to choke? If not, what could be causing this? If this is bad XML form, how would you reorganize it to work in Flash? --- FYI - FWIW: I am loading the XML in a standard way: var xmlObject = new XML(); xmlObject.ignoreWhite = true; xmlObject.onLoad = Delegate.create(this, loadSuccess); xmlObject.load(home.xml) and the delegate function just moves the playhead once the file is loaded - when I get to the frame after it's loaded, I do a trace on the XML and see the truncation as described. -- Ideas? Jason Merrill | E-Learning Solutions | icfconsulting.com NOTICE: This message is for the designated recipient only and may contain privileged or confidential information. If you have received it in error, please notify the sender immediately and delete the original. Any other use of this e-mail by you is prohibited. ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Question for XML Style Junkies
You shouldn't use the CDATA tag in an XML attribute. But if you are really desparate to put HTML formatting in XML attributes You can use URL Encode the attribute values with an escape() function... then have Flash unescape() the attributes when you load it back into flash However this is only useful if you are dynamically building your XML with script or dynamically building it from outside of flash then reading back into flash. --Keith H-- I am assuming the way I am using CDATA tags are throwing it off somehow.For example, I have a CDATA tag inside an attribute value under the Home/Panel/Panel[0]/Title attribute value and this is where it seems to break. Is this bad form and/or causing Flash to choke? If not, what could be causing this? If this is bad XML form, how would you reorganize it to work in Flash? --- FYI - FWIW: I am loading the XML in a standard way: var xmlObject = new XML(); xmlObject.ignoreWhite = true; xmlObject.onLoad = Delegate.create(this, loadSuccess); xmlObject.load(home.xml) and the delegate function just moves the playhead once the file is loaded - when I get to the frame after it's loaded, I do a trace on theXML and see the truncation as described. -- Ideas? Jason Merrill | E-Learning Solutions | icfconsulting.com NOTICE: This message is for the designated recipient only and may contain privileged or confidential information. If you have received it in error, please notify the sender immediately and delete the original. Any other use of this e-mail by you is prohibited. ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
RE: [Flashcoders] Question for XML Style Junkies
Thanks - and yeah, this XML will eventually be built dynamically from a ColdFusion script - I think I will just stay away from using CDATA inside attributes. Thanks to everyone who responded. Jason Merrill | E-Learning Solutions | icfconsulting.com -Original Message- From: [EMAIL PROTECTED] [mailto:flashcoders- [EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: Thursday, March 16, 2006 1:46 PM To: Flashcoders mailing list Subject: Re: [Flashcoders] Question for XML Style Junkies You shouldn't use the CDATA tag in an XML attribute. But if you are really desparate to put HTML formatting in XML attributes You can use URL Encode the attribute values with an escape() function... then have Flash unescape() the attributes when you load it back into flash However this is only useful if you are dynamically building your XML with script or dynamically building it from outside of flash then reading back into flash. --Keith H-- I am assuming the way I am using CDATA tags are throwing it off somehow.For example, I have a CDATA tag inside an attribute value under the Home/Panel/Panel[0]/Title attribute value and this is where it seems to break. Is this bad form and/or causing Flash to choke? If not, what could be causing this? If this is bad XML form, how would you reorganize it to work in Flash? --- FYI - FWIW: I am loading the XML in a standard way: var xmlObject = new XML(); xmlObject.ignoreWhite = true; xmlObject.onLoad = Delegate.create(this, loadSuccess); xmlObject.load(home.xml) and the delegate function just moves the playhead once the file is loaded - when I get to the frame after it's loaded, I do a trace on theXML and see the truncation as described. -- Ideas? Jason Merrill | E-Learning Solutions | icfconsulting.com NOTICE: This message is for the designated recipient only and may contain privileged or confidential information. If you have received it in error, please notify the sender immediately and delete the original. Any other use of this e-mail by you is prohibited. ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Question for XML Style Junkies
CDATA is a type of node - can't put CDATA in an attribute. Jim Kremens On 3/16/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: You shouldn't use the CDATA tag in an XML attribute. But if you are really desparate to put HTML formatting in XML attributes You can use URL Encode the attribute values with an escape() function... then have Flash unescape() the attributes when you load it back into flash However this is only useful if you are dynamically building your XML with script or dynamically building it from outside of flash then reading back into flash. --Keith H-- I am assuming the way I am using CDATA tags are throwing it off somehow.For example, I have a CDATA tag inside an attribute value under the Home/Panel/Panel[0]/Title attribute value and this is where it seems to break. Is this bad form and/or causing Flash to choke? If not, what could be causing this? If this is bad XML form, how would you reorganize it to work in Flash? --- FYI - FWIW: I am loading the XML in a standard way: var xmlObject = new XML(); xmlObject.ignoreWhite = true; xmlObject.onLoad = Delegate.create(this, loadSuccess); xmlObject.load(home.xml) and the delegate function just moves the playhead once the file is loaded - when I get to the frame after it's loaded, I do a trace on theXML and see the truncation as described. -- Ideas? Jason Merrill | E-Learning Solutions | icfconsulting.com NOTICE: This message is for the designated recipient only and may contain privileged or confidential information. If you have received it in error, please notify the sender immediately and delete the original. Any other use of this e-mail by you is prohibited. ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com -- Jim Kremens ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
RE: [Flashcoders] Question for XML Style Junkies
CDATA is a type of node Ah! - the light bulb comes on over my head. That should have been obvious to me. Thanks! Jason Merrill | E-Learning Solutions | icfconsulting.com -Original Message- From: [EMAIL PROTECTED] [mailto:flashcoders- [EMAIL PROTECTED] On Behalf Of Jim Kremens Sent: Thursday, March 16, 2006 1:57 PM To: Flashcoders mailing list Subject: Re: [Flashcoders] Question for XML Style Junkies CDATA is a type of node - can't put CDATA in an attribute. Jim Kremens On 3/16/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: You shouldn't use the CDATA tag in an XML attribute. But if you are really desparate to put HTML formatting in XML attributes You can use URL Encode the attribute values with an escape() function... then have Flash unescape() the attributes when you load it back into flash However this is only useful if you are dynamically building your XML with script or dynamically building it from outside of flash then reading back into flash. --Keith H-- I am assuming the way I am using CDATA tags are throwing it off somehow.For example, I have a CDATA tag inside an attribute value under the Home/Panel/Panel[0]/Title attribute value and this is where it seems to break. Is this bad form and/or causing Flash to choke? If not, what could be causing this? If this is bad XML form, how would you reorganize it to work in Flash? --- FYI - FWIW: I am loading the XML in a standard way: var xmlObject = new XML(); xmlObject.ignoreWhite = true; xmlObject.onLoad = Delegate.create(this, loadSuccess); xmlObject.load(home.xml) and the delegate function just moves the playhead once the file is loaded - when I get to the frame after it's loaded, I do a trace on theXML and see the truncation as described. -- Ideas? Jason Merrill | E-Learning Solutions | icfconsulting.com NOTICE: This message is for the designated recipient only and may contain privileged or confidential information. If you have received it in error, please notify the sender immediately and delete the original. Any other use of this e-mail by you is prohibited. ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com -- Jim Kremens ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
Re: [Flashcoders] Question for XML Style Junkies
Sorry for late response, Jason. I would use: content title![CDATA[SomebrHTML Text in brhere]]/title body![CDATA[Lorem Ipsum Paragraph Text Here]]/body /content As Jim noticed, CDATA is a type of node . -- Best regards, GregoryN http://GOusable.com Flash components development. Usability services. --- Merrill, Jason wrote: I am assuming the way I am using CDATA tags are throwing it off somehow. For example, I have a CDATA tag inside an attribute value under the Home/Panel/Panel[0]/Title attribute value and this is where it seems to break. Is this bad form and/or causing Flash to choke? If not, what could be causing this? If this is bad XML form, how would you reorganize it to work in Flash? ___ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com