That did it! Perfect. Thanks much!
On Oct 17, 2006, at 1:41 PM, Alain Rousseau wrote:
If you do a sendAndLoad allready, you should try to define your xml
in the
onData event of the LoadVars.
import mx.utils.Delegate;
var xml:XML = new XML();
xml.ignoreWhite = true;
lv.onData = Delegate.create(this, parseData); // onData returns the
source
of the file as a string so the parameters are passed without the
need of
arguments
lv.sendAndLoad( ... ); // Do your stuff here
function parseData(src:String):Void {
xml.parseXML(src);
// or this should work as well
// var newXML:XML = new XML(src);
}
HTH
Alain
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Chip Moeser
Sent: 17 octobre 2006 12:41
To: Flashcoders mailing list
Subject: Re: [Flashcoders] LoadVars to XML object
Is there a way to do this without specifying a URL in sendAndLoad? or
without actaully sending it out anywhere? I have a php page which
in an
initial load vars sendAndLoad is sending back xml. SInce Flash
see's it as a
string I just want to convert it to an xml object without sending
it out
anywhere again.
Thanks!
On Oct 17, 2006, at 12:26 PM, Cedric Muller wrote:
var xml:XML = new XML();
xml.ignoreWhite = true;
xml.onLoad = function () {
trace(this);
}
var lv:LoadVars = new LoadVars();
lv.sendParam1 = "bla";
lv.sendParam2 = "blo";
lv.sendAndLoad(url, xml, "POST");
hth,
cedric
Hello All,
I am trying to convert the return string of a loadvars to an XML
object. Does anyone know a simple way of doing this?
Thanks!
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com http://training.figleaf.com
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com http://training.figleaf.com
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training http://
www.figleaf.com
http://training.figleaf.com
--
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.408 / Virus Database: 268.13.4/478 - Release Date:
2006-10-17
--
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.408 / Virus Database: 268.13.4/478 - Release Date:
2006-10-17
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com