Is it possible to open Camera instance from Web App?
I have a Web App. displays something, and I want the user to be able to Take a picture and send it to the
server. How can I achieve this?
Is it possible to open Camera instance from Web App?
I have a Web App. displays something, and I want the user to be able to Take a picture and send it to the
server. How can I achieve this?
Using cordova apis it's easy
Check out the following code sample:
JS:
HTML:
Hope that helps.
If you're looking to go straight WebApp, you might want to look into the
File
input type for forms.Specifically, in iOS 6, they added the ability to submit a picture from either the camera or the gallery using just a
<input type="file">
within a form. You could then set the form to be sent to the server, and accept the incoming file.This has the added benefit of not needing to build an app, not needing to try to get it through any approval process, etc. It's also pretty commonly supported as well. According to this File Upload Support on Mobile page, it's supported in iOS 6+, Android 2.2+, BlackBerry 6+, and Windows RT.