Everybody! This is important. In a few days, these forums will be moving over to using the totally sweet Discourse platform. To ensure this migration happens smoothly with no loss of content, these forums are currently in a read-only mode. I do apologize for the inconvenience.

There is never a good time to turn the forums off for an extended period of time, but I promise the new forums will be a billion times better. I'm pretty sure of it.

See you all on the other side in a few days, and if you have any (non-technical) questions, please e-mail me at kirupa@kirupa.com. For technical questions, try to find a tutorial that corresponds to what you are looking for and post in the comments section of that page.

Cheers,
Kirupa

Results 1 to 4 of 4

Thread: Flash variables call XML

  1. #1

    Problem calling XML with Flash variable

    Hey everyone...

    First off all, thank you so much. All your tutorials, articles and forum questions have helped me so much in developing a website that is now almost finished...

    Only my most important part isn't working, my text content!!!
    I have this problem:
    I want my Flash menu buttons to contain a certain variable/string like for example: content_xml.firstChild.firstChild.
    Then I want to goto a frame where my XML file will load and insert the string here for retrieving data from XML, but I just can't seem to get it to work...
    When I set a variable IN the XML load function it works fine, but when I put it out it doesn't work anymore. And it has to be a global variable which loads on the first frame of the main movie.

    Hope you guys and gals can help me.. I'm really stuck here.

    Jellybean
    Last edited by Jellybean; April 12th, 2005 at 03:42 AM.

  2. #2
    If your putting it outside the onLoad then maybe the XML data isn't even in there yet when you try to assign the variable. Didn't really understand the structure of the whole thing.

    Cheers!

  3. #3
    Let me rephrase it different.. Because my first wuestion is indeed a bit hard to understand....

    How can I load an XML on start and load the different elements into different global variables...
    I need this to make my menu call the different text into dynamic text boxes when I click the coresponding button.

    Is this better? A bit I hope.....

    Hope you can help me guys!

    Jellybean

  4. #4
    Assuming you have the XML load all setup, then just assign the nodevalue you want to a global variable:

    Code:
    _global.myGlobalVariable = this.firstChild.childNodes[0].nodeValue;
    If you don't have the XML load all setup up then check here:
    http://www.kirupa.com/developer/acti...dataflash2.htm


    Cheers!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Home About kirupa.com Meet the Moderators Advertise

 Link to Us

 Credits

Copyright 1999 - 2012