0 Replies Latest reply on Apr 23, 2007 8:12 AM by NC Web Guy

    Passing info from a XML file to URLloader

    NC Web Guy
      I am new to Flex (And programming alltogether), so please excuse my ignorance when asking this question; but I have to start somewhere. :-)

      I have an application using HTTPService that pulls information from a XML file and displays an image and text within the window depending on the selected item. The image and text appears as needed from {data.image} or {data.text} calls to their appropriate field. On that same window, I want to add a link button that will direct the browser to a new page depending on the selected item. I have the link for each item embedded in the XML file, but I cannot figure out how to pass the link to the button.

      I have tried to create a function, but the URL isnot passed to the broswer. The application tells the browser to go to "{data.link}" at the local server, not the actual URL.

      my function looks like this:

      public function newPage():void
      var getLink = '{data.link}';
      var request:URLRequest = new URLRequest(getLink);
      var loader:URLLoader = new URLLoader();