I've searched everywhere, but can't find one thread/result that suits my situation.I'm trying to post data into a database, through php. I don't want to reload the page, so I want this to happen through Flash. I thought about using the LoadVars() class, but it just simply isn't working.How would I about doing this? Say I have three variables, blah1, blah2, and blah3, all of which are strings. How do I send these variables to a php page with the POST method?
Im pretty new with the flash -> php -> mysql thing .. And I have made a script that sends some variables (that a user inserts in some input forms) with some var names, and then php handles it and insert it into my MySQL database its kinda ugly that a page pops up and opens the php page.So I was wonderin' if there is some way to send the variables to the php file and process them inside the flash file. without openin' some fancy browser window ?
I'm trying to create a file that shows data from a database depending on an id number the user inputs in Flash. I am having trouble sending to PHP the id so it sends back the appropriate data from the db.
This is the AS3 code that tries to send the value of the idNumber to PHP[code]...
Can i put ACTIONSCRIPT inside a xml file and make it work inside a swf?Since is not basic, where can i learn more about xml processing instructions?Other thing....Can a php file that send variables to flash WITHOUT the swf ask for it?
I'm pretty inexperienced with actionscript, and I'm having the hardest time trying to figure out how to load variables from a file and send it to a dynamic text box. The content of an external file, "varload.txt", is "name1=John". Here is actionscript of my flash file:
Let a qualified-user place a dot on a country map and this dot will be shown on the map. When other users come by they see dot's and those dot's trigger a image.
1 Create a map, duh
2 Use the mouse to get the coordinates (_x and _y position) onRelease will be the selected coordinates.
3 Create a preview-scene were the qualified user sees the placement of his dot.
4 If oke, a image upload scene is triggered (the selected _x and _y coordinates are hidden)
5 The qualified user selects a image on his computer.
6 Again a preview scene, now with the dot on the map and the selected image.
7 If oke the user sends the coordinates and image to the server (i will use php-files to upload the info and a mysql-db to store the info)
I am stuck with step 2. In the attach file you can see what i have so fare.The trace messages are the data i want to send to a php script. And think i must create an array in flash something like:
Code: coords = new array(); for (i=0;i<=v;i++)[code]...
You gotta see the attach .fla to understand this. I have the values collected in "controller" movieClip.
I have the livedocs wide open and I still can't figure out how to send off multiple variables in an object (from a class) to the FLA file...[URL] The setup: I have a class that extends EventDispatcher. I created an Object called _pass, public var _pass:Object;. In my last function (everything is cool up until now), I have four variables that need to be passed to the main fla. Let's say they're param1, param2, param3, param4.
It was explained to me that I could use the public var _pass:Object; by first creating an instance of the object like so, _pass = { param1, param2, param3, param4 }; (each param is available in the function). Having setup an object instance, I could then dispatch the object to read from within my fla: dispatchEvent(new Event(Event.COMPLETE));.
But I get these errors:
1084: Syntax error: expecting colon before comma. 1083: Syntax error: rightbrace is unexpected.
As the livedocs show, you can use an associative array (with braces and a colon), but I don't need that. I just need to pass my variables that are pre-made to the FLA.
I'm looking to send a list of variables (say 6 in total) from php to flash and for flash to pick a random one and send it back to php when clicking a button.
I would like it to appear in a dynamic text box. That randomly selected variable needs to be sent back to php on pressing a button.
I'm looking to send a list of variables (say 6 in total) from php to flash and for flash to pick a random one and send it back to php when clicking a button. I would like it to appear in a dynamic text box. That randomly selected variable needs to be sent back to php on pressing a button.
I desperately need to send variables from AS3 to PHP. I have been searching and trying for days to work it out but nothing seems to work. I have a swf which will be used for quotes, each part asks things like size, colour and other options. It has a summary part at the end that shows everything that has been added. I want to send these variables with there values to a PHP page to send an email. I can work out the PHP bit and I have tried several things to get the variables sent to the PHP but nothing seems to work. I want to send the variables to php when the submit button is clicked, it goes to the test PHP page which should then print the variables but it is blank.
Here is the code I have at the moment: ActionScript Code: btnSubmit1.addEventListener( MouseEvent.MOUSE_UP, function(evt:MouseEvent):void { PHPSendData() var myData:URLRequest = new URLRequest("test.php") try { navigateToURL(myData, "_self") } catch (e:Error) { [Code] .....
I'm new to AS3 so not too sure about anything but I'm not even sure if I need the loader bit or the function doComplete but I have tried it with and without and it doesn't make a difference.
Im trying to make an swf send a phone-number to a specific asp-fil on the press of a button.But since I'm an as3 rookie I have no idea where this code is going wrong (PLEASE HELP):[code]
I know when I was connecting to my database in my last project I used PHP, however I need to use JSP for this project and I can't find any info on google, it just seems to be flash remoting with PHP.
how can i send variables to asp... that's all i want.
this is what i have...getURL("webform1.aspx?id=1&status=I",0, "GET");
but everything this gets send to asp... it also loads a new browser... i would like to continue with my flash movie from section 1 to section 2 and just send 2 variables to asp to let them know that i have finish section 1... that's all.
I have written the following to call in a text file via php and evaluate the contents for duplicates. If there are dupes, it identifies and removes them and resaves as a new array to send back and overwrite the current php. It identifies the dupes perfectly and assembles the new array as well. Unfortunately, it's not sending the new contents (myLV) to the php in my sendAndLoad.
I suspect that part of my problem is that it's all encased in the onLoad function which is embedded in another function, but I cannot get the initial variables to load from the php any other way.
Here's my AS:
function upDate() { var playerData:LoadVars = new LoadVars(); playerData.onLoad = function() { var currentNames:String = this.blog;
Well, I made a login page with flash and php. So I was wondering how can I make it so that I can send variables to another frame.
Like I have a button, when you press it, it connects to the database, and it checks your login. Then it gets all the variables. So how can I get the variables for every page on my flash project?
The only way I can think of now, is setting a dynamic text to the variable..
How can I send two seperate variables? I know I can use & in the middle of that code, and pass another value, but this will place both values into the variable myVar. Can I just do a new one underneath like
I am trying to send some variables from my actionscript 3.0 to PHP file.. but if i am using POST method I am getting an error instead if I use GET method it is working fine but then there comes the security issue. All my variables are displayed in URL which I dont want to happen. This is my code:
I need to retrieve data from a text file, sort it with a new added score, and then turn the whole data back into a string and save it back into the text file.
I have worked on mini .swf files and php files, and I can seperately:
- retrieve data from a text file to Flash
- do the sorting in Flash from a string coming from a text file
- send a string to a php file and save it on a text file
But I cannot seem to do the three at the same time! Here is my [code]...
I have a simple banner that has three choices. A, B, and C. When a user clicks on one of the choices...I just need a counter to make note of it...in some remote file. Php I would guess.So the end result is that you could access the php file and see that choice A was clicked however many times, and choice B was clicked so many times, etc.But I am not a Php guy and don't know what syntax to use to make this happen.
Am trying to make a good form, butm i have problems whit SEND button, when i click in, it only go and play it didnt send anything, i put this on button :
I'm making a flash form and I just want to send some variables to a php page but not show a new window or anything. And the variable is huge so I want to use the post method. It's also posted from a component therefore movieclip.loadVariables doesn't work?
I'm trying to send an email with 3 input text fields to a PHP script.The input text fields are populated and I've tried using LoadVars and loadVariables and getURL, none of which have worked. I trace the text fields and they have values, and the PHP script is reached and it sends the email but not with the right content that it is supposed to receive from AS.what's the deal? I would also prefer not to open another window as in the target property of the getURL function but would like to give confirmation of receipt directly in Flash.[code]
I know you can send all the variables using: url...Is there a way to do this but only send the variables I want to? Say I only wanted to send "user" and "pass" but not "content".
I have an email form in a flash file. Currently I am using the send variables coding as for whatever reason, it doesn't function if I use loadvariables:Here's what I have set up on my submit button:
I have three movie clips that I am using as buttons. Their instances in the movie are Espanol_btn, Francais_btn and Deutsch_btn. I have added script to control the rollover and press/release states of the buttons, and now need to get the script to recognise which of the three buttons was pressed, store that result in the variable called lang (The posibilities are Espanol, Francais or Deutsch), and depending on what the variable land is, do different things. The script is below.how I can get this to work.
Code: import mx.transitions.Tween; import mx.transitions.easing.*; var lang:String;[code].....
I saw that there are lots of ways to send info or values from flash to PHP. But is there a way to do the REVERSE? Send variables or values from a php to a flash and this same flash movie react to those values?
I have a simple banner that has three choices. A, B, and C. When a user clicks on one of the choices...I just need a counter to make note of it...in some remote file. Php
So the end result is that you could access the php file and see that choice A was clicked however many times, and choice B was clicked so many times, etc.
But I am not a Php guy and don't know what syntax to use to make this happen.