Solved

Confused about load vs parseXML

Posted on 2006-06-28
4
149 Views
Last Modified: 2010-04-03
Greetings

I am fooling with a gallery, which I need to draw from dynamically created XML. The gallery, however, has the following hard-coded;

if(_root.xmlFile==undefined){
      _root.xmlFile="gallery.xml"
}
imageXML.load(_root.xmlFile);

My first solution was to change this to;

if(_root.xmlFile==undefined){
      _root.xmlFile=(_root.MYVARS)
}
imageXML.load(_root.xmlFile);

Where MYVARS was specified in the URL string:

<param name="movie" value="new1.swf?MYVARS=gallery.xml">

That way I can have the same flash file access many different galleries. However, what I REALLY need is to load the vars right in the embed/object tags, like so;

<param name="movie" value="new1.swf?MYVARS=<gallery>more xml stuff</gallery>">
or
<param name="movie" value="new1.swf"> <PARAM NAME="FlashVars" VALUE="&?MYVARS=<gallery>more xml stuff</gallery>">

However, I have tried to change the gallery actionscript to the following;

if(_root.xmlFile==undefined){
      _root.xmlFile=(_root.MYVARS)
}
imageXML.parseXML(_root.xmlFile);

And this doesn't work. Am I missing something? Help! I'm under the gun to get this working, after a solid day of messing about.
0
Comment
Question by:seanostephens
  • 2
4 Comments
 
LVL 37

Accepted Solution

by:
CyanBlue earned 500 total points
ID: 17003673
Howdy...

You could try this...

MYVARS="<gallery>more xml stuff</gallery>"
_xml = new XML(MYVARS);
trace(_xml.firstChild.childNodes);

CyanBlue
0
 
LVL 37

Expert Comment

by:CyanBlue
ID: 17058943
Have you try that???  :)

CyanBlue
0
 

Author Comment

by:seanostephens
ID: 17625098
This didn't work (I gave up) - but CyanBlue should get some credit, as his concept was where I had gone...
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
AWAY 3d Using BitMapCubeTexture 1 402
Flash player updates using SCCM 2012 and SCUP 2011 3 392
System Center Configuration Manager 2012R2 7 81
Java and adobe flash updates 4 44
This is a very simple example to help those of you who are still migrating from AS2 to AS3 understand the redesigned event model in AS3. In AS2.0, event functions (that is, the function to be performed when an event is fired) were stored as a pro…
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
The goal of the tutorial is to teach the user how to use the auto adjust feature and what the different options do. When your video is not working right you can choose the auto adjust feature to help choose your settings.
This Micro Tutorial will teach to how to utilize bit rate in Adobe Flash Media Live Encoder.

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now