Url from xml file

guess i should rather shut down the comp and get drunk !
i’m totally stuck trying to implement a url link into the attached scroller
it’s “fed” by an xml file - i would like to have the scroller to open a blank new url delivered by the xml file but it won’t work.
the attached file is in flash 8 / AS2

any help is appreciated

I was having a similar problem, trying to get a link from an XML. I was searching everywhere when I discovered a really simple code.

text box name.htmlText = “<a href=”"+name of your variable+"" target="_blank">"+name of link title variable+"</a>";

Looking at your code, it looks like you’d want to add in something like this:



item._y = (item._height+space)*i;
item.titel_txt.text = tempxml*.attributes.titel;            
item.z1_txt.text = tempxml*.attributes.z1;
item.z2_txt.text = tempxml*.attributes.z2;
item.z3_txt.text = tempxml*.attributes.z3;
item.z4_txt.text = tempxml*.attributes.z4;
item.z5_txt.htmlText = "<a href=\""+tempxml*.attributes.z5+"\"
target=\"_blank\">"+tempxml*.attributes.z5+"</a>";
item.link.
item.btn.ID = i;


You also need to change whatever Dynamic Text Box to “Render as HTML.” It works great for me, you can apply this to any of the text boxes and can use your URL variable or create a new variable for just the name of the link. In this case, the URL works fine.

i made 2 right decisions:

  1. i went out to get massively drunk
  2. i asked for help here
    both worked out perfectly !!

thanks a lot - works like a charm

Glad I could help with one of your problems. :slight_smile:

Looking through your file, it looks like something I plan on doing in a later project. I hope you wouldn’t mind if I used it as a base for this project later?

no restrictions !
grab the code and do whatever you like with it