news.volyx.in

TIL: You can access a user’s camera with just HTML (austingil.com)

576 points by feross · 1464 days ago · 231 comments on HN

Article summary

The HTML capture attribute allows a user's camera to be accessed with just HTML, specifically on mobile devices. When a user interacts with an input element with the capture attribute, it opens the device's camera instead of the default file picker. The attribute can be set to 'user' or 'environment' to access the front or back camera, respectively. This feature is useful for mobile users who need to take a picture or video for upload.

Main themes

  • HTML capture attribute
  • mobile device camera access
  • security and privacy concerns
  • desktop device limitations
  • user experience and usability
  • corporate firewall and filter issues

What commenters say

  • Some commenters think the feature is cool and useful for mobile users, while others are concerned about security and privacy implications.
  • The feature does not work on desktop devices, which some commenters find disappointing.
  • Some users cover their phone cameras when not in use due to security concerns, while others do not see this as a necessary precaution.
  • The capture attribute does not prompt users for permission to access the camera, which some commenters see as a potential security risk, while others argue it is not a concern since it only provides access to the captured file.
  • Some commenters discuss the limitations and potential uses of the feature, including its inability to display the camera image on-page.
  • Others share their experiences with the feature, including issues with corporate firewalls and filters blocking access to demonstration sites.