开发者

Raw jpg post from flash to php. How to save the jpg image? The image is corrupted

I am getting a raw jpg post from flash into a php script and saving the image in a temp folder in the server. The image is saved, the size is correct, but when I try to open it I get an error message saying that it is corrupted.

Here is the php code that I a开发者_如何学Cm using:

<?php
$data = file_get_contents('php://input');
$result = file_put_contents("imagePathOntheServer/image.jpg",$data);
echo $result;
?>

Any ideas? Your help will be much appreciated.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜