New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No Picture returned from the Camera Plugin #174
Comments
And as mentioned from the the plugin update thread: iOS:
Android:
WP:
|
I've also hit this issue with my So far only tested on Android 4.4.2 Galaxy S5 (Geny Motion) with Touch 2.3.2 and PG 3.5.0 Android:
I stepped through the JS code and it all looks ok so I'm assuming that the Java code is behaving differently based on Android permissions. I used this code example: http://phonegap.com/blog/2013/11/20/SenchaPhoneGap/ |
Closing since we haven't seen very much activity on this issue. Feel free to reopen. |
I'm not sure if what I'm experiencing is related to this or not... I'm using the PG Developer app to test my app before jumping through the hoops of compiling it on its own. In both Android and iOS I'm able to choose photos from the camera roll and view them in my app. Then I would like to upload them to my server. On Android this is working as expected. On iOS it appears that nothing is sent. Via console.log I can see that the file uri (on ios) is Here's my upload code:
If this is a known issue with the PGD app, and given that it works on Android, if I can expect it to work on iOS once compiled to my own app, then I can live with that. Is that the case? |
Hi @atuttle I don't believe this is a known issue within the PhoneGap Developer App. It should work once you switch over to your own compiled app. However I would look at the server logs first to see at least the app had tried to upload the image. If you can see maybe a 404 or at least any status code that indicated that the app tried to reach the server, that'd be a good place to start. Otherwise, if there is no indication then we can dig into this issue further. |
Thinking it might be the size of the uploaded file I tried uploading a screen shot of my iPod instead of a photo, but the same thing happens. I can see that the request from iOS is sent to my server, but the server is complaining that the file field from the upload is missing/blank; which is a bit odd as I can see it listed as a field when debugging and it has a nonzero length... What baffles me is that it's the same code running on both iOS and Android, and it works fine from Android. This leads me to believe it's not the server-side code but something with the app / permissions to send the file, maybe? |
To follow up, after I started building my app on its own, the problem went away. I don't know what plugins the phonegap developer app has installed, but I'm making use of FileTransfer and the File plugin. I could see how not having one or both of those could be problematic. At any rate, I'm on my feet. Thanks for your attention! 👍 |
Hi @atuttle Well, glad to hear it's working for you! |
On all platforms, when launching the camera app via the camera plugin, a user is able to take a picture using the camera plugin but the picture is unaccessible to the app. This relates to the same origin policy error where we are attempting to access the file uri where the picture lives from a different origin.
The text was updated successfully, but these errors were encountered: