I have a sketch pad made in Flash AS3 like this one here: http://henryjones.us/articles/using-the-as3-jpeg-encoder
I want to send the jpg to the server and some data from a html form field with php. Is there a way to force the Flash movie to deliver the image file when one presses the submit button?
it’s a little tricky: You can do it one of two ways:
Arthem posted this in another thread:
And I usually use this solution:
I haven’t used the imageshack API, but you may want to try using adobe’s JPGEncoder class – here’s a quick example that passes a username and the JPG’s byte array, it’s really quite simple.
Note that the variables are passed as part of the query string. You can’t use URLVariables, as several people have suggested, as the URLVariables would be stored in the request’s data property, which we are already using to pass the byteArray.