search

Home  >  Q&A  >  body text

javascript - Help, how to call the camera to take pictures in html5? ?

The project has a requirement, which requires calling the user's camera to take photos and upload documents. Can this be achieved? Are there any cases to share?

capture=”camera” attribute Only the browser in the iPhone can recognize the camera. Some built-in browsers in Android series phones can, but most of them cannot.

ringa_leeringa_lee2869 days ago629

reply all(4)I'll reply

  • 我想大声告诉你

    我想大声告诉你2017-05-16 13:40:12

    http://www.html5plus.org/doc/...

    reply
    0
  • PHPz

    PHPz2017-05-16 13:40:12

    input file image/*

    reply
    0
  • ringa_lee

    ringa_lee2017-05-16 13:40:12

    Uploading is very simple. Please note that the function of dropping the photo album under Android requires native cooperation. Turn on the function permission of dropping the camera. It is very simple on h5. See Liezi for details
    https://my.oschina.net/zyxchu...

    reply
    0
  • 巴扎黑

    巴扎黑2017-05-16 13:40:12

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

    reply
    0
  • Cancelreply