How to access a mobile's camera from a web app?

夏期劇場 picture 夏期劇場 · Dec 20, 2011 · Viewed 295.5k times · Source

In my web app (not native app) for mobiles, I want to take a photo and upload it, but I don't want to use Adobe Flash. Is there any way to do this?

Answer

Ashish picture Ashish · Nov 21, 2012

In iPhone iOS6 and from Android ICS onwards, HTML5 has the following tag which allows you to take pictures from your device:

 <input type="file" accept="image/*" capture="camera">

Capture can take values like camera, camcorder and audio.

I think this tag will definitely not work in iOS5, not sure about it.