0
我使用danialfarid/ng-file-upload和bcabanes/ng-camera。这是我的代码(咖啡):从ng-file-upload上载ng-file-upload到干预图像
file = $scope.vm.picture
if (file)
Upload.upload({
url: "::imagenes/store",
fields: {'Title': "test"},
file: file,
headers: {
'Accept': 'application/json;odata=verbose', 'content-type': 'image/jpeg', 'X-RequestDigest': $("#__REQUESTDIGEST").val()
}
}).success((data, status, headers)->
console.log('Complete!');
);
我的导航显示(慢)的数据进行发送,但我不知道如何保存与Laravel干预的形象。下面是一些代码:
$file = Request::file("file");
$info = explode(".", $file->getClientOriginalName());
我不知道我是否可以使用支持::文件(“文件”),因为它是由NG-卡马拉采取一个base64形象:
ng-camera(
capture-message="Sonrie!"
output-height="320"
output-width="426"
crop-height="320"
crop-width="426"
image-format="jpeg"
jpeg-quality="100"
action-message="Tomar foto"
snapshot="vm.picture"
flash-fallback-url="/images/webcam.swf"
shutter-url="/sounds/shutter.mp3"
style="display: inline-block")
怎么办我发送base64图像,如何保存它?感谢您的帮助!