# Some assistance w/ loading XML

**URL:** <https://forum.kirupa.com/t/some-assistance-w-loading-xml/242735>\
**Category:** flash\
**Created:** [October 29, 2007, 10:15pm UTC](https://forum.kirupa.com/t/some-assistance-w-loading-xml/242735 "2007-10-29T22:15:28Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dynastyjp](https://avatars.discourse-cdn.com/v4/letter/d/34f0e0/32.png) [@dynastyjp](https://forum.kirupa.com/u/dynastyjp)\
**Post date:** [October 29, 2007, 10:15pm UTC](https://forum.kirupa.com/t/some-assistance-w-loading-xml/242735/1 "2007-10-29T22:15:28Z")

</div>

I’ve created a small animation for my companies product lunch with various animated tag lines.  
We’d like the tag lines to be dynamic (my boss is convinced he wants to be able to swap out tags every so often). Loading XML into a dynamic text field is easy enough.

What I am stumped by is loading multiple tag lines into various dynamic text fields with just one XML file. I’m assuming I can have multiple xml files that load into a designated text field but that just seems messy to me. I know it’s an easier way than that. Any help would be appreciated. I was making sure I was able to load xml into one dynamic text field and I used the following code.

var output\_xml = new XML();  
output\_xml.ignoreWhite = true;  
output\_xml.load(“testxml.xml”);  
output\_xml.onLoad = function(success){  
if (success){  
var zoomswitch = this.firstChild;  
var textNode = zoomswitch.firstChild;  
tag\_1.htmlText = textNode.nodeValue;  
}else tag\_1.text = “Error loading XML”;  
}

Any help or pointing me in the right direction would be appreciated.Thanks.
