views:

1713

answers:

2

i created xml in flex after that creation i post to php via http service but when i add like xml in http service flex throws error msg like Error #1096: XML parser failure: Unterminated element." What did i worng ? How to send xml data flex to php ? plz refer me

<mx:HTTPService id="createxml"  method="POST" url="http://####/admin/?do=storebettingdetails" useProxy="false"></mx:HTTPService>var xm:XML = new XML("**********"); ------ adding child node -- Thend attached xml to service like createxml.request=xm;

createxml.send();

+1  A: 

in script make your xml variable

[Bindable]
private var xml : XML = new XML("xml code");

and in mxml, on your httpservice component make:

<mx:HTTPService id="createxml"
         method="post"
         url="http://....../?do=storebettingdetails"&gt;
    <mx:request>
        <myxml>{this.xml}</myxml>
    </mx:request>
</mx:HTTPService>

you will get the xml in php as $_POST['myxml']

TheBrain
A: 

Thank you very much for the answer