ActionScript 3.0 :: Send Both Bytearray And Form Data?

May 11, 2010

I'm currently working on a small project. The user is supposed to draw/do a puzzle within flash, and also fill out a form with his details and comments.

When clicking the send-button, the image should be sent along with the form as an email.

I already know how to send the image as an email via php, and I know how to send a form as an email via php, BUT - I can't seem to do it together.

I've googled a bit and I found out that I cannot pass both the bytearray (from the image) and the form-data as URLVariables at the same time.

One way I got it to work is by passing the values from the form-data as a part of the URLRequest (and then use $_GET in the .php-file), but this has limitations as it can only pass 100 characters. As the user should be able to comment on his work, using GET with its limitations isn't an option.

View 2 Replies


Similar Posts:


Php :: Flex - Send A FLV Format Data In ByteArray Using URLloader To A Script?

Dec 15, 2010

Im creating flash game that have the functionality to capture/record its gameplay that can be viewed later by the user, like a replay.

As for now Im already able to record the game and write it into a flv format in a ByteArray variable.

What Im working right now is how to send that ByteArray(the video file) to a php script and save it to a web server.

I've run into the URLLoader in flash where it can send the data and php will receive it thru the POST method. Unfortunately, the ByteArray containing the flv data must be first correclty encoded for php to read it. I figured this out from the example in the net where it does the same thing only that it is only sending a JPEG ByteArray instead of a FLV format using the JPEGENCODER.

Is there any existing class like the JpegEncoder for FLV format or any Video formats? Or any work around like creating the encoder my self?

here is my current code to send the ByteArray

//send byteArray to a php script
var request:URLRequest = new URLRequest(url);
request.method = URLRequestMethod.POST;

[Code]....

View 1 Replies

Php :: Send More Than One 'stream' Of Jpeg ByteArray Data In A Single URLRequest And Output 2 Images?

Jan 25, 2011

I have an AS3 swf which users can upload jpg images to my EC2 instances which sit behind and Elastic Load Balancer. The jpg images are converted into bytearray data and sent using URLLoader.load(URLRequest)I make 2 calls when uploading, one to upload a large version, then another to upload a thumbnail version. A PHP script to which the bytearray data is uploaded converts this to a file using file_put_contents($destination,$GLOBALS["HTTP_RAW_POST_DATA"])Is it possible to combine these two requests into a single request which contains both the bytearray data for the large and thumbnail images and 'split' the HTTP_RAW_POST_DATA to create 2 files at the server. This would be better than uploading the bytearray for the large version then using something like ImageMagick to resize the resulting image into a thumbnail which I realise is another option.

View 1 Replies

Data Integration :: Load/send XML Data Via HTML Form?

Jul 26, 2006

I currently have a Flash app that gets populated by parsing data from an external XML file. However, I need to get the XML data into a (JSP) session and can't neccesarily have an external XML file--any suggestions? Can I put the XML string into a hidden input field in a form on the HTML? Can Flash communicate with that HTML? Or are one of the below methods recommended:

* FlashVars

* Flash Remoting

* Web services

* JavaScript - call JS function

* fscommand

* ExternalInterface

View 1 Replies

Php :: Cannot Send All Of Flash Form Data

Apr 6, 2011

I have a flash form that sends a monthly report that users fill out to a php file, which sends it to a MS SQL database. This issue I am having is that anything larger then 1300 characters entered into the flash form will not work at all. If I reduce the amount of text to 1300 characters or less, it will send it to the php and database just fine. My research shows that a flash variable should be able to handle 65,000 characters, and when I trace my output from flash to php, all of the data is being traced. however, it is not being send to php. I am using LoadVars to send the data with _GET. So is this a php issue, or a flash issue? I ran a php info page and my max_post is set to 10M that should be enough to handle this load. I am not sure why it is not working with anything larger then 1300 characters. Below is my code for my php and flash files.

The variables that are affected by this are the testEvlauation, projects, support, and programManagement variables. I need them to send at least 8000 characters a peice to the php file.

Flash Code:

on (release) {
sendData = new LoadVars();
sendData.contractor = contractor.text;
sendData.name = name.text;

[Code]....

View 1 Replies

ActionScript 2.0 :: Send Data (not In Form) To PHP

May 1, 2006

I have a page on my website that allows users to download some files using filereference. When the user clicks on the button to start the download, I want to pass the name of the button (the name of the file they are downloading) to a php script to put in my database, so I have a record of who download what.

I have no problems passing normal form data to php using the loadvariables, but since I want to send info that is not an input text box, I have no idea how to go about doing this.

View 8 Replies

ActionScript 3.0 :: Send Data From Flash Form To PHP?

Feb 11, 2009

I have a flash form (widget) on a website that the user can enter details (or select them from drop down menus).

There is then a submit button at the bottom.

This is quite primitive, and as far as my flash allows me. The bit I am stuck with is that I need to send the data then to a .PHP file that will then forward this to the correct people (this bit is already done for me).

sending this information (e.g. Phone Number, Country, Language etc) to the .PHP file.

View 3 Replies

Data Integration :: Send Email Form To ColdFusion?

Apr 7, 2007

I am trying to send data filled out in a form in my flash movie to send mail using CFMAIL. In my form that is in Flash I have variables set. Then when the button is pressed loadVariables("sendMail.cfm", "POST");

Then on my CF page I have this:

<cfmail from="info@mysite.com" to="#FORM.email#"
SERVER="mail.mysite.com" >
#FORM.comments# #FORM.company# #FORM.name#
</cfmail>

I can't find a tutorial on this. Everything is PHP. And I don't want to use "Flash Forms in MX7"

This is all embedded in my Flash web site.

View 2 Replies

Ruby On Rails - Send Form Data To HTTPService?

Aug 5, 2009

The form is in a component lauched as a popUp, form data consists in:

login:String
password:String

I thought of a few different ways, but I don't like them..in the popUp, send button triggers a function that gets the form values and stores them in an Object, then saves the Object in the model, then dispatches a CreateSessionEvent. The CreateSessionCommand execute method is called, and it send the HTTPService passing the object from the model. (but then what if the model somehow doesn't get update and I send the same request twice?) I could try to get the form data from the command execute method itself.. how can I access them though, since it is a popUp (created with PopUpManager.createPopUp(this, LoginDialog),true))

I'd love to see an example flex+rail with restful xml application by the way, know of any?

View 1 Replies

ActionScript 3.0 :: Send The Form Data To A MySQL Database?

Feb 28, 2011

What I am wanting to do is create a "registration form" and send the form data to a MySQL Database. Once the user submits the form, a password is created and emailed to the user.

Then once all has been created and stored, the user can log in and gain access to secure pages.

View 9 Replies

ActionScript 3.0 :: Load XML And Grab Data To Send As Variables To A PHP Form

Sep 3, 2009

I have an .SWF that is a "Share With A Friend" and the text fields are filled in and then the SWF sends the variables to sendToFriend.php and then the email is sent out.. The PHP is working fine and I have all the right codes to send that information from the SWF to to PHP, but the client wants another feature I can't figure out..

They want me to grab data from an XML and use those variables as well, because the XML will have the USER EMAIL and I need to grab the specific data from the XML and I can't find anything that does this..

I barely know where to start. Maybe a simple tutorial that doesn't just load the XML and display the content (I have found that), but rather something that loads the XML, then refers to a specific child and turns the text to a variable to get sent to PHP..

EXAMPLE XML

<client>Joe</client>
<email>JOE@JOE.com</client>

How do I load the XML and directly refer to the <email> information so my PHP file can grab "JOE@JOE.com" ???

View 0 Replies

Simple Flash Form Variable - Collect Data From A Form, Then Pass That Data To An Asp File?

Oct 19, 2009

I am trying to create a simple form using Actionscript 3 that will collect data from a form, then pass that data to an asp file. I have attached the following code to the submit button,but this is not working.I'm not sure if I have to add anything else and I don't understand why this is not working. I'm trying to load all the variable info into one variable called email form.

submit_btn.onRelease = function() {
var emailform:text;
emailform.email_txt = email_txt.text;[code]......

View 1 Replies

ActionScript 2.0 :: Creating A Flash Form And Using .php To Send The Form To Myself?

Sep 16, 2005

I was following 1 of the flash tutorials about creating a flash form and using .php to send the form to myself.I've followed all the instructions but upon uploading, the file just doesn't seem to work. I hope to have some kind of form in my new website.

View 4 Replies

Send A ByteArray To FMS?

Sep 23, 2011

Who knows how to send a ByteArray to FMS?

View 1 Replies

As3 :: Javascript - Flex - Send A Jpg Image As ByteArray

Jan 10, 2010

How to send a jpg image as ByteArray from as3 to javescript? And how to convert ByteArray to image in javascript?

View 3 Replies

ActionScript 3.0 :: Send A Bytearray Object To A Javascript Function?

Aug 11, 2009

I need to be able to send a bytearray object to a javascript function or a java method, but I was wondering if I could do it using XMLHTTPRequest.

import asfiles.encoding.JPEGEncoder;import flash.display.Bitmap;import flash.display.BitmapData;import flash.external.[code]...

So I have a video that plays stream from a webcam,I will click a button and take a picture. I encode that picture using JPEGEncoder then I store it in a ByteArray.How do I send that data over to either a javascript function or a java class?I don't want to use the navigateToURL (URLRequest) method because that will redirect my page.Is there a way to send the data to a function while still staying on the same page?For example, make a asynchronous call to a javascript function or java method?

View 1 Replies

Php :: Send An Actionscript ByteArray As A POST Variable (within Facebook)

Dec 18, 2010

I would like to use Flash to send a ByteArray (of a PNG image) to a php file, in a facebook application. Is there a way to do this by sending the ByteArray as just one POST variable instead of as the entirety of the POST data?

There was a nearly identical question here: How can I send a ByteArray (from Flash) and some form data to php? but the problem is different; instead of smuggling other variables in other parts of the request, the image itself has to be sent as just a variable because Facebook commandeers the post data and puts in its own junk.

If not, can I send the image in some form other than a byteArray?

View 2 Replies

ActionScript 3.0 :: Send ByteArray To Flash Without Using Php_amf Extension

Oct 3, 2010

I'm working on a Flash tool that needs to send some data in the form of a flash.utils.ByteArray instance to PHP (amfphp service class) and get that data back from the amfphp service as flash.utils.ByteArray instance. Now I can do all of these with the php_amf extension enabled on the local WAMP server. And the tool works fine. But how can I achieve this without the php_amf extension? I'm deploying on a shared hosting server and I don't have access to the php.ini and also the dl() function of PHP is disabled for security reason. With the extension disabled, I can send the ByteArray instance to PHP and save the data to DB. But the problem arises when I try to retrieve the data from DB, create a ByteArray instance (amfphp helper class) with the data and send back to Flash. I'm guessing here that proper AMF message is not being constructed because of the absence of the php_amf extension.

View 1 Replies

ActionScript 2.0 :: Send Data To A CGI Script Via GetURL And Not Have A Popup Window On Send?

Mar 11, 2004

I searched around and found some helpful things, but I am still missing something I think...

LoadVariables() won't work across domains, right, so, is it porrible to send data to a CGI script via getURL and not have a popup window on send?

View 3 Replies

Send Email From F8 With GoDaddy's PHP Form?

Jun 27, 2006

I am trying to create an email form in Flash 8 that sends mail to my hosting account email address. GoDaddy says that you have to use their coding, but how do I get this to work with Flash 8?Can anyone give me a hand? Below is a link to GoDaddy's write up on creating a PHP form-mailer.URL...

View 21 Replies

ActionScript 2.0 :: Send Flash Form Value To Jsp?

May 24, 2007

Now i am doing one flash with actionscript project. It,s one real game with fun project.But problem is i am using JSP for server side and front end is flash with actionscript.My problem is how to send flash values to jsp and then stored to database.I serch lot of websites i cannot founf it anywhere

View 3 Replies

Flash :: Where's A ByteArray's Data Stored

Oct 29, 2011

I'm using URLStream to download a big file and save locally on a mobile app. To do this, i need to store the downloaded bytes on a ByteArray:

private function handleStreamProgress(event : ProgressEvent) : void {
if ( urlStream.bytesAvailable == 0 ) return;
if ( urlStream.connected ) {

[Code]....

Are these bytes from the downloaded file stored in Memory? (Profiler doesn't show any excessive memory consumption, though...)

Should I clean the byteArray after each sequence of bytes is stored?

View 1 Replies

ActionScript 3.0 :: Use As3 And Php Together To Send Form Info To Email

Jun 15, 2008

i have about 10 fields most input text boxes and then about 4 check boxes...i have no clue how to use as3 and php together to send the form info to an email.

View 1 Replies

ActionScript 2.0 :: LoadVars - Form Can't Send With GET / POST

Jun 19, 2011

I have a very simple form to send user data to a php file

when i run my form from FLASH PROFESSIONAL it send without problem

but when i run SWF or html with SWF no matter on lacal disc or website it doesn't work[code]...

View 1 Replies

ActionScript 2.0 :: Email Form - Send Button Does Nothing?

Jul 3, 2005

Had a customer purchase a template, customized it to suite their needs only thing was it has a built in email part to the flash which came with no php script ....and for the life of me I cannot get it to work properly, [url]if you go to the contacts page you will see the form I am referring to. If any one here who knows the php and action scripting well, please give this a look see. I cannot get it to send mail, clear button works fine, send button just does absolutely nothing, sits there and looks pretty.I have tried 4 different action scripts with this thing and am at my wits end.

View 8 Replies

ActionScript 2.0 :: Send IP Address In Contact Form?

Jul 8, 2005

How would I gather the same information that's possible in an HTML form? For instance, I would like to get the IP of the sender, such as:<input type="hidden" name="env_report" value="REMOTE_HOST, REMOTE_ADDR, REMOTE_USER, HTTP_USER_AGENT">I've been getting so much spam from my Flash site, I have to figure this out.

View 7 Replies

ActionScript 2.0 :: Form To Send Mail To EmailAddress

Jan 19, 2006

I made a form in flash to send a mail to an emailaddress, when I export the .fla to .swf, then it works correctly. But when I insert that .swf in a .html-document and run this in a browser, it won't work! What could be the reason?

Flash MX Pro 2004:
var senderLoad:LoadVars = new LoadVars();
var receiveLoad:LoadVars = new LoadVars();
verzenden.onRelease = function() {
senderLoad.bedrijf = bedrijf.text;
senderLoad.emailadres = emailadres.text;
[Code] .....

View 3 Replies

ActionScript 2.0 :: Mail Form Send + Go To Next Frame?

Jan 29, 2008

basically its a submit button with action script, the button sends of the php file and thats all grand...

on (release) {
// send variables in form movieclip (the textfields)
// to email PHP page which will send the mail

[code]......

View 3 Replies

ActionScript 2.0 :: Contact Form Comes To Send A Mail

Sep 30, 2008

I have a contact form and i have a little problem when it comes to send a mail. I have the string message saying that the message has been sent but the receiver just get an empty message, empty email address from the sender etc... in other words the mail get send but it is empty.

View 3 Replies

ActionScript 3.0 :: Contact Form Send The Information Through?

Dec 3, 2009

I am trying to get down to the bottom of my problem with a contact form I'm using for a client. My code is as follows:

[code]...

The issue I'm having is that when I hit the submit button on my form, it doesn't send the information through. It just stays stuck on sending.... and doesn't send any information. I then ran a test with an even simpler code:Just to see if it was even connecting and I recieved this error:

Warning: mail() [function.mail]: Failed to connect to mailserver at "127.0.0.1" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in

D:hostingmembershieldvhmmailtest.php on line 2

Now I don't have access to the host server because I'm not the owner. I just designed the site for the client and I have been having these issues with the form. I did test it on my server and everything worked fine which led me to believe that the problem lies in the php settings of their host server. I contacted the host server and this is what they sent me:
"Dear client, 127.0.0.1 is localhost which you cannot use to send email. Please make use of your mail server to and send and provide SMTP authentication to the remote server. Note that the FROM address has to be the same as login email.

View 2 Replies







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