我正在使用以下代码尝试从 iOS 照片库中选择一张照片:
navigator.camera.getPicture(this.onCaptureSuccess, this.onCaptureFail, {
allowEdit: true,
correctOrientation: true,
destinationType: Camera.DestinationType.FILE_URI,
soureType: Camera.PictureSourceType.PHOTOLIBRARY,
targetHeight: 315,
targetWidth: 320
});
我在 iPhone 5s 和 PhoneGap 3.3.0 上使用 iOS 7 (7.0.4)。无论我做什么,它总是会调出相机。我做错了什么?
最佳答案
我觉得我找到了:
soureType: Camera.PictureSourceType.PHOTOLIBRARY,
应该是:
sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
sourceType 有错别字。也许就是这样?
关于ios - 如何在 iOS 上使用 PhoneGap 从照片库中获取图片?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20916536/