Click to See Complete Forum and Search --> : Flash to PHP
Lost Student
05-14-2004, 05:32 PM
hey..
can someone remind me how to recieve a variable in PHP sent from flash using sendandload..
cheers
Lost Student
05-15-2004, 04:35 PM
hey all..
answered my own question its the HTTP POST VARS..
my next problem is that the send and load is failing!.. it is fine when inside a test file on its own but when i cut and paste the code into the .fla im working with the send and load fails..
What is the most common reasions for this and why would it work in one file but not another?
first frame of timeline:
simple_lv = new LoadVars();
//the function when data is recieved back
simple_lv.onLoad = function(success:Boolean) {//works in another file
if (success) {
sametxt.text = this.same;
name_txt0.text = this.newname0;
name_txt1.text = this.newname1;
} else {
name_txt0.text = "oh no";// i keep getting this..
}
};
button.onRelease = function() {
simple_lv.myname = _parent.user.name;
simple_lv.sendAndLoad("name.php", simple_lv, "POST");
work.text = myname.text;
phpsee.text = simple_lv.myname;
};
stop();
any ideas?
cheers all
Musicman
05-15-2004, 04:52 PM
Hi,
probably the most commom source of this problem is testing inside flsh rather than in the browser
Musicman
Lost Student
05-16-2004, 07:59 AM
not sure i get you there?.. both the test and the actual project are being viewed through a browser.
the only diffrence between the two is the place from which the PHP script gets its starting variable..
thanks..
Musicman
05-16-2004, 03:48 PM
Could I have a look at these things (swf installed on a server, not a fla)
Musicman
Lost Student
05-17-2004, 06:03 AM
its ok iv cut the elements out of the proper file into the working one.. was just one of those times when the most basic thing wont at all?
last week a stop action on the timeline didnt work... flash can be weird sometimes..
thanks for your help.
flashkit.com
Copyright WebMediaBrands Inc., All Rights Reserved.