Php :: ByteArray To MySQL From ActionScript 3 -> PHP Via ZendAMF

Dec 1, 2010

I have an ActionScript 3 application that's sending an object to PHP via ZendAMF. The object contains a byteArray from an image.

I have it currently saving the byteArray into a Blob like so:

[code]...

This seems to be working fine and I can see the image in the DB (this is running local and I'm using SequelPRO to view the DB).

The problem is when I'm sending the byteArray back to Flash, Flash reports the byteArray length as 0.

View 1 Replies


Similar Posts:


Actionscript 3 :: Introduce A Sound From The Library To A ByteArray (and Then Play That ByteArray)?

Feb 16, 2011

I am working on a game, made with Flash (using AS3) The game has a fast ball and when this ball hits an object it has to make a sound... but the sound starts with delay (so the ball is far away when the sound is played).This sound is edited by me and it hasn't got any silences at the beginning.The method i'm currently using is the simplest one:

public var sonidoPuntos1:sonidopunto1 = new sonidopunto1()

and then...

sonidoPuntos1.play()

I am trying to introduce the file into a ByteArray and then playing it from there...

View 2 Replies

Php :: ZendAMF Have Private Members?

Jun 9, 2009

I've worked with AMFPHP for a while, but with Adobe supporting ZendAMF, I was wondering if I should migrate.

One of the major disadvantages for AMFPHP is that class mappings need to be public, so not only does that mean public members on the PHP side, but also on the Flex side. I was wondering if it is the same case for ZendAMF.

View 1 Replies

Php :: Traffic Going Between My Flex Application And ZendAMF?

Aug 8, 2011

I am using ZendAMP php and Flex (Flash Builder 4). It works great, but I noticed when I am looking at the traffic going between my flex application and ZendAMF, there packets moving even though I am not requesting communications in my code.For example, this is what my service looks like in flex:

var activityLogService:RemoteObject = new RemoteObject("zend");
activityLogService.showBusyCursor=true;
activityLogService.endpoint="http://myserver:80/amf/";[code].........

Are these just some kind of 'keep alive' messages?If so, is there a way to turn them off? Also, if so, is there a way I can use them to keep some kind of session alive on the server side maybe (maybe that's what they are for)?

View 1 Replies

Actionscript 3.0 :: Difference Between ZendAMF And AMFphp

Jul 15, 2009

Whats the scoop?I watched Lee's tutorial on Zend and also the older ones for AMFPHP.Is one 'better' than the other? Doubt that since as I understand both are written by the same author, only Adobe 'officially' supports Zend.

My application is composed of 3 parts

1-an image editing tool allowing users to upload images, edit them, then post them to a server.

2-a publicly viewable gallery

3-a private 'admin' tool allowing the user to change their login settings and delete any uploaded images.

Are both Zend and AMFPHP equally robust and easy to implement when it comes to session registration and login?

View 1 Replies

Actionscript 3.0 :: ZendAmf Own Class Fails

Aug 4, 2009

I am using ZendAmf with an example Tutorials of Lee and files downloaded from this forum.

This is the client actionscript code :
Code: Select allvar nc:NetConnection = new NetConnection();
nc.connect("http://localhost/myfiles/zendTest.php");
var res:Responder = new Responder(onResult,onError);

[code]...

View 2 Replies

Actionscript 3.0 :: ZendAmf Will Not Work On Webserver

Feb 28, 2010

ive tested my files countless times using WAMP but when i put them on my webserver i cannot get anything to happen when i call the swf

[Code]...

when i goto index.php i see "Zend Amf Endpoint", and as i already said when i use a backup copy of my_db using WAMP i receive the information

View 6 Replies

Actionscript 3.0 :: Implement The Introduction To ZendAMF Without Success ?

Dec 27, 2008

I've tried to implement the Introduction to ZendAMF without success

I'm getting this error on publishing the flash file:

Code: Select allError opening URL 'http://localhost/folder/'
Error #2044: Unhandled NetStatusEvent:. level=error, code=NetConnection.Call.Failed

- I'm in localhost on Windows with Xampp.

- If I open in the browser the url of nc.connect() it returns "Zend Amf Endpoint".

- If I print the return of the Tutorials.getTutorials() from another script the returned array contains the correct data.

View 5 Replies

PHP :: ZendAMF Returning Invalid XML And Causing Bad Version Error

Sep 1, 2010

I am trying to use ZendAMF to do remote method calls to a MySQL database from Flash and I keep recieving the NetConnection.Call.BadVersion error.
My Server is working correctly. Apache 2.2.14
My PHP is working correctly. PHP 5.2.11
My Database is working. MySQL 5.0

My first problem was a security error in Flash. If you try to run a local SWF from the Flash IDE to a web service online, you'll get a security warning which will throw the BadVersion error. However, the security error won't show up if you 'TEST MOVIE' so it took me a while to realize that. I changed my testing process to remove this variable. I am now able to implement my php class code successfully using AMFPHP, which essentially rules out my class as the issue (I think). It seems to be a problem with the Zend implemntation of AMF.

I have followed a tutorial from Lee Brimlow here: [URL]. I was unable to get this to work locally, and I've moved my content onto a web server and can call the Class and Method from my SWF. I've used Charles to view the response. When I go to validate the response in Charles I get this:
Validator: Failed to Parse XML Document.
Reason: An invalid XML character (Unicode: 0x0) was found in the CDATA section.
Line: 65 Column: 87
Can it be handled in PHP?

Here is my ZendAMF code:
<?php
error_reporting(E_ALL|E_STRICT);
ini_set("display_errors", "on");
ini_set("include_path", "./frameworks");
require_once 'Zend/Amf/Server.php';
require_once 'Animal.php';
[Code] .....

View 3 Replies

Actionscript 3.0 :: Zendamf Not Handling Special Character Data

May 29, 2009

I've written an application that deals with multiple languages, English, French, etc, I'm using Zendamf to retrieve multi-language data from a database, however, I'm running into a problem using Zendamf, and it could kill this project fast:

There seems to be an issue passing special character values via Zendamf. While querying a database that returns data including French-text characters (ie: Québec), the result returned from Zendamf is not handling the special characters (ie: instead of Québec, we receive Qu�c).

I've checked the output of the data via Php: the issue is not with the database result - the characters are returned correctly from the database to the Php result-set - I am able to print these characters correctly before they are sent through Zendamf, either by rendering them in HTML or by writing them to a log file.

However, once I plug the SQL result into an object and pass it to Zendamf, the special characters get mangled. Using Charles Web Debugging Proxy, I can see that the result values are mangled before they are passed back to my AS3 application.

View 1 Replies

Mysql :: Migrate A Preexisting Flex/Java/Hibernate/MySQL App Onto A CD For Portable Distro?

Feb 2, 2011

I have a typical Flex-based application that was written to use a Java/Hibernate/MySQL backend. The client changed the requirements - now they want to distribute it on a CD where the user can just run the app without any installation or a network connection.

To do this, I certainly need to eliminate the web server and the database server and adapt my application (with as few changes as possible, of course) to a stand-alone application that will fit on a CD/DVD. I've managed to export the data to XML and read it into Flex, but I'm wondering if there's a way to recreate the Hibernate data structures in Flex so I could change as little code as possible. Failing that, is there any way to keep the existing Java/Hibernate external to the Flex code but retrievable without installing Apache Tomcat or MySQL?

View 3 Replies

Mysql :: Create An Insert Form With TextInput Containing ComboBox Provided By MySQL Database Table?

Jan 13, 2010

I have a Flex application which manage a database composed by 7 tables.I have created the insert form and all work great. Now I wanto to improve the Form performances; the idea is to replace the TextInput of the Form with ComboBoxes which are provided by the DataBase tables

View 1 Replies

ActionScript 3.0 :: Convert Wav ByteArray To Mp3 ByteArray?

Mar 28, 2011

I know its a true Pain but does anyone know any way to convert wav ByteArray to mp3 ByteArray.

View 1 Replies

Configure MySQL JDBC Driver Mysql-connector-java-5.1.12?

May 25, 2010

I have downloaded MySQL JDBC driver from [URL]... How do I configure it?

View 1 Replies

Mysql :: Accent MySQL-Flex/ZendFramework?

Oct 22, 2011

In my table the Collation is:latin1_swedish_ci (but i tried UTF8_unicode too).In my flex application when it shows the table,it displays it correct,with all accent and pointing correct,but in the table is like :

View 1 Replies

ActionScript 3.0 :: ZendAMF Error Handling - Make The PHP File Throw An Exception That Gets Traced As An Error Message

Jul 7, 2010

i am currently trying to learn ZendAMF, but i have a hard time troubleshooting which makes learning it quite hard. Is there a way to make the PHP file throw an exception that gets traced as an error message in AS3 (not Flex), the only error i seem to be able to get is "Error #2044: Unhandled NetStatusEvent:. level=error, code=NetConnection.Call.Failed", but it tells me jack ****.

i have gotten ZendAMF working, i just want to know how i can make error handling better, so that as an example can use PHP to tell flash that no results were found, or that the typed text was invalid. Is it better to use AS3 to check if the field was filled properly?

View 1 Replies

Send A ByteArray To FMS?

Sep 23, 2011

Who knows how to send a ByteArray to FMS?

View 1 Replies

IDE :: Creating A Swf With ByteArray

Jul 14, 2009

I am trying to create a new swf with AIR and Flash CS3. All I want to do is push a button and have a new swf saved to the desktop with a line of actionscript in it. The actionscript can be anything stop(); - for instance.I have been messing around with ByteArray and I can save an image to a swf but I can't find any information on what I want to do.

View 2 Replies

ActionScript 3.0 :: Use ByteArray Or Something Else?

Dec 12, 2010

at the current status of my project i must write an application (With AIR or ZINC) who its job is:

1st-getting some files from user. 2nd-modify them with an algorithm (encryption or encoding or changing byteArray) to simply corrupt the file and make it impossible for other applications to read the corrupted file!

[Code]...

View 4 Replies

ActionScript 3.0 :: UTF-16 Representation In A ByteArray REgards

Jan 17, 2010

Is there a way to write a UTF-16 string into a ByteArray in Flash/AS3? Basically I have a string (var test:String="allan"; for example) and I would like to write that into a ByteArray with UTF-16LE encoding. In this case it would be "61 00 6C 00 6C 00 61 00 6E 00".
 
I've tried using utf16le.writeMultiByte( clipText, "utf-16" ); but it just comes out with what appears to be UTF8 (or just straight ASCII given the test string).
 
The use case is to save a UTF-16LE file using FileReference.save(), which I understand I can do by passing it a ByteArray with the correct character encoding in it. Passing just a string saves as UTF-8. Hence the need to convert and store into a UTF-16LE representation in a ByteArray.

View 13 Replies

Actionscript 3 :: BitmapData To ByteArray?

Jul 28, 2010

I am trying to serialize a Bitmap to store in an XML file. My plan is to turn the BitmapData into a byteArray, but I haven't been able to fine an example of this.

View 1 Replies

Xml :: Loading Bytearray Into XML Object?

Oct 14, 2010

I get Index out of bounds when trying to readObject on my Byte array into the XML object.

private var fr:FileReference;
private var data:ByteArray = new ByteArray();
[Bindable]
private var dataXML:XML = new XML();[code]....

The Byte array is created by loading a file using FileReference

View 2 Replies

Flex - SWF To Bytearray From A PHP Script?

Nov 7, 2010

i'm using AMFPHP to stream content from my server to my Flex application, since Flash is a clientside technology i would like to make it harder for people to grab protected files, so i created a system that streams swf file to another flash player, i've done all the testing on URL stream, now i want to pass the swf file to the player as bytearray .. since i think it's safer and harder to break and in the future i even might do some encryption of my own if i became more familiar with bytes and bits .. anyways is my method the best one? (SWF to ByteArray?) or is there a better one? if the bytearray method is the best, i am facing a problem in outputing the swf file in the right format, i'm using a very primitive method .

[Code]...

View 1 Replies

Flex - Loading Swf With Bytearray In AIR?

Jan 25, 2011

We have requirement with the AIR application which loads the flex generated swf which inturn loads the flash generated swf using SWFLoader. This is not working as desired.This gives the following error: SecurityError: Error #3226: Cannot import a SWF file when LoaderContext.allowCodeImport is false.

[Code]...

View 2 Replies

Php :: Flash - Sending ByteArray Through PHP?

Mar 22, 2011

The BLOB field (pic) is turning out as 0 Bytes when trying to send ByteArray through as3 to PHP, so i assume the PHP script or the HTTP_RAW_POST_DATA isn't working.I think the Flash part is working, I have set a trace() to see if the bitmapdata is coming through and it seems it is, so I'm assuming its my php side.3

private function export():void
{
var bmd:BitmapData = new BitmapData(600, 290);

[code].....

View 2 Replies

ActionScript 3.0 :: Mp3 Creation Using Bytearray?

Feb 2, 2010

I want to make a flash application in which i will load 3-4 different mp3 files of different instrumental music. After loading it I want play all files. Further I want to save or create a merged mp3, from all mp3s sound files in a single mp3 file.

Is it possible to convert different mp3 sound track in to different ByteArray and later using any other technology like PHP or C# can we merge all byteArray in a single byteArray to create a single mp3 file.
So that we can listen all instrument playing in a single mp3 file.

View 8 Replies

ActionScript 3.0 :: Load Swf As Both ByteArray And Swf?

Mar 31, 2011

I have a load of information in a swf that I'm loading at runtime. From that swf I need to get raw vector data out of some MovieClips, and other MovieClips I need to instantiate and put on the stage.Currently I can get at the vector data by loading the swf as a ByteArray using a URLLoader and parsing it with a bit of help from as3swf.

However, if I want to instantiate one of the MovieClips directly I would usually load it with a Loader and get at the MovieClip via loaderInfo.applicationDomain.My question is: can I either load the swf as a ByteArray with URLLoader and somehow instantiate MovieClips from that, or can I load the swf as a DisplayObject using a Loader, get the MovieClips and then convert the swf to a ByteArray before giving it to as3swf for parsing?

View 2 Replies

ActionScript 3.0 :: Does Recording From Mic Into ByteArray Usually Lag?

Mar 11, 2012

Summary: is there usually a lag when recording audio from the mic? I am using Thibault Imbert 'micrecorder' library on google code to record audio from the mic into a ByteArray. I am instructing my users to speak two seconds after the recorder starts. I know its two seconds after the recorder starts, rather than two seconds after the user presses the record button, because micrecorder issues time adjusted events of the recorder progress.

When I get the finished ByteArray the actual floats inside it that record the user speaking seem to be 2.5 seconds worth of samples into the ByteArray! So my question, as this is the first time I have recorded audio, is it usual to find a lag like this when recording? Or do you think I am getting something wrong with my math when indexing into the ByteArray?

View 0 Replies

ActionScript 2.0 :: Load An FLV Into A ByteArray?

Oct 26, 2006

Any way to load an FLV into a ByteArray, modify it (maybe add a water mark) and pass it to the Video Object for display?

View 2 Replies

ActionScript 3.0 :: ByteArray Reading Long Value?

Dec 28, 2011

I have a java server sending the time with:long time = System.currentTimeMillis();I put this in a packet. It takes up the first 8 bytes of the packet and send it to the as3 client.Then in as3 I read the packet but since there is no readLong function with ByteArray, I can only think of reading it with readDouble to read the first 8 bytes of the packet. I'm not sure if this is the right way to do it.

I compared it with the time from AS3's function: Date().time;The time I get from AS3's Date().time is different than the time I receive from reading the packet with the time sent from the java server.I'm not sure if I'm using the wrong time functions or reading the packet wrong.

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved