The Flash movie makes a HTTP POST to your server-side script, using the Content-Type 'image/jpeg'. This is a NON-STANDARD method which is unlike submitting a form from a web page. If you are using PHP, the JPEG data will NOT be in the normal
$_POST associative array. Instead, you should read it from the special PHP wrapper: 'php://input'. For example:
$jpeg_data = file_get_contents('php://input');
You can write this raw, binary JPEG data to a file handle using the PHP function file_put_contents():
Any output from your script is passed back through the Flash movie to the JavaScript code, which in turn passes it to your onComplete callback function.
For example, if you want your script to pass back a URL to the JPEG image, save the file where you want it, and construct a URL to the file. Then simply print the URL to the output like this:
(This assumes you are saving the files to the current working directory)
aibip
Member
134 Points
185 Posts
Re: Convert PHP img upload script to VB.net
Jul 31, 2011 11:35 PM|LINK
Server Side Code
The Flash movie makes a HTTP POST to your server-side script, using the Content-Type 'image/jpeg'. This is a NON-STANDARD method which is unlike submitting a form from a web page. If you are using PHP, the JPEG data will NOT be in the normal $_POST associative array. Instead, you should read it from the special PHP wrapper: 'php://input'. For example:
$jpeg_data = file_get_contents('php://input');You can write this raw, binary JPEG data to a file handle using the PHP function file_put_contents():
Any output from your script is passed back through the Flash movie to the JavaScript code, which in turn passes it to your onComplete callback function.
For example, if you want your script to pass back a URL to the JPEG image, save the file where you want it, and construct a URL to the file. Then simply print the URL to the output like this:
(This assumes you are saving the files to the current working directory)
(See "test.php" for a working example.)
I found this from this web site... It's over my head..
http://code.google.com/p/jpegcam/wiki/Instructions