Php :: Sending And Receiving Data?
Feb 28, 2012
Not getting data back into flash from php that queries mysql data, think the problem is with my as3 code here?The php works, the as3 posts to the php ok, its the returning of the variables to as3 that I am unsure about and seems to be the problem?
public static function MineData():void{
var myRequest:URLRequest = new URLRequest("login.php");
var myLoader:URLLoader = new URLLoader();
[code].....
View 1 Replies
Similar Posts:
Aug 4, 2009
We are thinking of adding a feature to a main page of a flash site that I will be building shortly, but it requires sending data out to an API where it will be processed and send back to Flash.The form will need to post a number of variables to a URL and then interpret the response code.. is this possible in AS2?
View 9 Replies
Jul 29, 2011
I know this is frequently asked, but I have looked all over the internet to find the mistake I'm making with the code I've used to send and receive data from AS3 to PHP and viceversa.Can you find the mistake? Here is my code:
AS3:
import flash.events.MouseEvent;
import flash.net.URLLoader;
[code].....
View 3 Replies
Jul 20, 2011
I'm trying to make a barebones, simple flash client communicate ANYTHING to a server over a regular socket. I setup the listeners:
socket = new Socket(); socket.addEventListener(Event.CLOSE, closed); socket.addEventListener (DataEvent.DATA, onSocketData); socket.addEventListener(Event.CONNECT, connected); socket.addEventListener(
[code].....
View 1 Replies
Jul 18, 2004
I've begun playing with Flash and XML Socket Servers and I thought I started taking to it easy, I was able to connect and disconnect to a socket server I wrote and Unity but I seem to be having problems sending and/or recieveing data. I wrote a small amount of code to try it out:
[Code]...
It seems to be connecting fine but when I click and I try my send,
View 2 Replies
Jul 9, 2011
I want to retrieve data from a Database and display inside a datagrid in a Flex web application. The way I'm thinking of doing it is :
Send the Query data from .mxml file to the .jsp page using HTTPService. In the .jsp, connect to the database and retrieve the data using select statements. send the results back to the .mxml using HTTPService.
I know what to use but I have an ambiguity. In the (.mxml) I use xxx.send() to send the data. What do I use in the (.jsp) to send it back ? I know that I should store the results in an XML in the .jsp file, but how to do that ?
View 1 Replies
Nov 6, 2010
I am trying to get an xml to load from an external site using a PHP proxy. I have been able to achieve this with the url of the xml hard coded in the PHP though I now wish to get the flash to send the url as a variable to the PHP though I am unsure how to do this.
[Code]...
View 3 Replies
Feb 11, 2007
All of the tutorials I have found re: local connections seem to outline 1 swf sending info & the other swf receiving. Is it possible to have two swfs using exactly the same action script for their variables to effect each other? I've got two swfs with 2 different sets of buttons who react the same way on roll over. Once a button is selected it remains highlighted. I want to know if I can have a button in swf 1 highlighted but un-highlight when a button in swf 2 is selected?
View 3 Replies
Jan 18, 2012
i am looking for some kind of library which does CRUD easily using PHP and MYSQL.My goal is to make some app in flash AS3.0 , where i will be receiving some data from user and storing in data base , and perform CRUD opertaions. I dont want to be so much involved in writing php and sl query.My scenario is:
Data types : [ like user_profile data, etc]
add under data types 1 to many fields with various types..
Database tables and realtions etc should be done by my DREAM library, then user when select a Dtat Type, he is presented with related fields to fill up data.
I will be using Flash AS3.0 ( Builder or IDE ) to perform .If only i can find some php library i think AMFPHP can connect flash with php
View 2 Replies
May 31, 2010
my first flash webpage sends data to a php script. I then do
var result_data:String = String(contactLoader.data);
if (result_data == "ok")
{
navigateToURL(strURL, "_self");
}
So if the data is sent with no problems, it will load up my new url. Problem is, this new url needs this data to display it. So, if my php file holds the data in variables, how can my new url retrieve these in real time? (meaning that data goes straight from swf to php to new swf) I have been trying LoadVars, but not sure if this will work in real time, maybe it will.
View 8 Replies
Jun 29, 2010
I'm setting up a kind of database, where the data are coming from a specific url.
I receive the source code of that url, get the data I look for, and display this in a text box. This works fine as long as I start the swf locally. However, when I copy the swf to my home page, the data obviously cannot be received anymore.
To make it more clear (with fictional url): Homepage [URL] contains the swf; tries to automatically read and display the source of [URL]
View 11 Replies
Aug 4, 2009
I'm writing a flash chat program using XMLSocket.It's connecting and sending data just fine. The server is sending the data back just fine (I checked the packets on Ethereal), but Flash is just not receiving any data.[code]The server is a Java server written with the NIO classes.
View 2 Replies
Sep 28, 2008
I have a problem with my code that I've realized to read data from txt file. My problem consist to receive data by call a method I've try a lot of ways but I'm not to be able to resolve it. I attach my code. This code is a class.
View 8 Replies
Jul 29, 2011
I'm goofing around with developing a Flash game that would be accessible via a Facebook application but am still trying to figure out how I want to organize the game itself. The game essentially is an educational game with competitive components - completing tests faster results in more points with which you can customize your avatar and other items in the game. Also, passing certain "lessons" open up new lessons. So the major components I see are:- Player data storage (scores, progress, etc.)- Social connections - transference of rewards, comparing high scores, etc.- Lesson data (what questions to ask, possible answers, etc.)How is this best controlled? PHP and SQL? XML? Should I use datagrids as an intermediary? I'm having a lot of problems finding good information, both on the internet and at the bookstore about how to manage this.
View 3 Replies
Apr 2, 2011
This is something I noticed on the Adobe documentation pages.
When receiving a textfile from a URL, the function to set the text will either look like this:
function completeHandler(event:Event):void {
var txt:String = URLLoader(event.currentTarget).data as String;
tf.text = txt;
[Code].....
View 2 Replies
Apr 18, 2011
I'm building an action that basically handles receiving post data from a flash app,I have no problem receiving the data. after that, it should redirect to another controller/action.I tried Redirect, RedirectToRoute, none of them worked.[code]
View 1 Replies
Jul 20, 2011
I'm trying to make a barebones, simple flash client communicate ANYTHING to a server over a regular socket. I setup the listeners:
socket = new Socket();
socket.addEventListener(Event.CLOSE, closed);
socket.addEventListener (DataEvent.DATA, onSocketData);
[code]...
And then I connect. On the server side I have a simple policy server on port 843.And then the real socket server that the flash client is connecting to.The flash client connects to the policy server and gets the policy. The flash client then connects to the actual socket server. I know this because I can both see it when snooping the network traffic and the fact that the Event.CONNECT fires off. From snooping the network traffic I can see the flash client send data TO the server when it:
socket.writeUTFBytes( "TEST CLIENT
");
From the server app I can see the data the client sent. The server then returns a little data. I can see this data going from the server to the client in the network traffic snooper. However, the client NEVER sees the data. It never fires off DataEvent.DATA or ProgressEvent.PROGRESS or ProgressEvent.SOCKET_DATA. There are no errors and the connection remains open for as long as I want it... but the flash client never seems to see the data... no matter how much I send.
Over and over I read online that the data sent to the flash socket needs to be terminated with a � zero byte. I can verify it is in the network traffic snoop.if I try to read any data from the flash app via something like readUTFBytes it always returns nothing found.
View 2 Replies
Apr 6, 2010
The component itself receives all its parameters from a .txt file. The editor is a read/save form that initially loads the parameters into it's form fields, and then overwrites the .txt file when the user hits submit. You then refresh the component on whatever website you have it to see the changes.Here's the php code that I found to get me going:
<?php //Capture data from $_POST array $title = $_POST['Title']; $comments = $_POST['Comments']; $image = $_POST['Image'] //Make one big string in a format Flash understand $toSave = "Title=".$title."&Comments=".$comments."&Image=".$image;
[code].....
View 2 Replies
Sep 11, 2011
I am trying to send a server "schooltraq.com/api/" variables for a request.My Code:
package
{
import flash.display.MovieClip;
import flash.display.Sprite;
import flash.events.*;
[code].....
How ever when I keep getting back "error:empty request". I emailed the site owner and he said that my program may be dropping the data during redirects.[URL]
View 1 Replies
Apr 9, 2007
I will be creating a program to use for data entry. I'll be studying zebras in kenya and I won't have the internet there as I'm recording the data. I'd like to be able to send the data I generate in flash to an external text file. I understand I need some sort of script to do that, but is this something I can run just on my machine? (I'll probably make the data into xml format).
View 1 Replies
Apr 10, 2007
I have an interactive Flash simulation that I have imported into SABA Publisher. I need for the Flash file to communicate with SABA, basically returning that the user has successfully completed the simulation. SABA is supposed to be able to receive data from Flash.
View 2 Replies
Feb 22, 2010
I know that the best way to make a connection from my main app to my modules is through interfaces.
So, my problem is, how can I implement an interface so my module can send and receive data from my main app?, cuz, I understand that my module implements an interface that is used by my main app.. but, can I do it "viceversa"?
Other issue I have is, why do I need to call my main app children if I can just import a module's class?.
View 1 Replies
Feb 3, 2011
I'm developing a web application with Flash CS5 and AS3.0. The problem I'm having is this:At a certain state, the application goes to a frame with a "loading..." animation that loops continuously until the next state is reached. The animation is inside a MovieClip that lives on this frame on the stage (I'm not creating or animating it dynamically). While in this state, the app is waiting to receive a large xml file from an XmlSocket connection. The file takes a few seconds (literally - not milliseconds) to be received fully by the Flash player, and during this time the loading animation stops. I believe the socket is blocking the animation thread until it's done receiving the entire file.Does anyone know of a workaround that would allow the animation to keep playing while the socket is receiving? I've seen pseudo-threading hacks, but those always deal with computations or other activities that can be accomplished by calling a call-back function multiple times. Since I'm just listening on an open socket, there's no callback I could pass to a pseudo-thread.
View 2 Replies
Mar 12, 2009
I am having trouble on sending my data to the php..I am using flash cs 3 and the code is what I copied from a site. here's the code.[code]I pasted this code to the button named 'submit' and when I checked the script for errors, my script has an error! it says:Statement must appear within on/onClipEvent handler and I don't know what does it mean I am just newbie in flash cs 3.
View 1 Replies
Oct 26, 2010
I am working to send data from as3 to php and I am having a little trouble with it. I am new to both AS3 and php but at this point I think I am doing fine.The project is simple it just takes two values from as3 and send its to php. But apparently I am not able to send variables from as3 to php. Here is the code(its very simple code):[code]I am sure the insert.php is working as I hardcoded the values in insert.php and it inserts the rows. So, I am assuming that there is some problem with sending the data from as3 to php.
View 2 Replies
Apr 4, 2008
how to send out some data to a PHP file. I have a project set up already where you vote for some options and that sends, but now I need to add some input text fields for people to enter some personal information. What I have right now are two fields with the vars of "name" & "email"And here's the code that is sending out the information to the PHP file:
Code:
submit.onRelease = function():Void
{
sendVars();
_root.gotoAndStop(2);
}
[code]....
I've tried a couple of different ways but so far all of them failed, they included creating another function like the "sendVars" function to send with the submit button and I also tried placing some code into the "sendVars" function relating to the "name" & "email" vars.
View 6 Replies
Apr 6, 2008
I made a flash file were people can fill in there name and then press enter and lateron there name will be visable in a other textfield with in the clip.Now i made the following script in frame 1:
Code:
enter_btn.onPress = function() {
if (input != undefined && input != "" && input != "fill in please"){
email = input;
gotoAndPlay(2);
[code]....
this works great, 'input' will bring the filled in name too the textfield with the var called 'email'.Now i moved the 'email' var within a different movieclip with a instance name of form.When i fill in the name in the beginning the 'input' var and 'email' var are not communication nomore. How can i make sure 'input' will give the data to the 'email' within the other movieclip ?
View 2 Replies
Dec 1, 2002
I have an swf called main.swf. from this movie I want to send some data to sub.swf which runs whenever any button on the main.swf is clicked. I want to use the data from main.swf to sub.swf. My query is how can I send the data from main.swf & how to get it in sub.swf. I tried using loadMovie & getURL function but dont know how exactly to use...
View 2 Replies
Mar 25, 2009
I need to make an Odometer and the user can adjust the numbers and once they select their klm reading it needs to be sent to a PHP to sent it to a database. I am having trouble finding a way to send the data. Is it possible to make a "field box" and what ever number is in the box when you push submit sends to the php?
View 1 Replies
Mar 28, 2009
how to send data from a flash to a database and how the receive it aswell. Im presuming you pass the data from the flash to a php file to the database when sending and call the data using a php file to the database aswell. What im trying to do is just have a button that will increment a number in a database by 1 and then display that information on a different Frame within the flash later.
Basically what i want to do if have a button pressed to increment a number in a database.
View 6 Replies