Reputation: 1017
I want to scan a QR code from my website and i'm using the html5-qrcode
js library.
It is working properly from safari
or whatever browser I use it in.
It asks for permissions, then makes you select the camera you want to use
and finally shows you the preview of the camera
If I add my website to the homescreen this behavious changes...
I can click the button to allow permissions to use the camera
but after a few seconds it looks like the permit I just granted gets denied and the camera just won't start.
This seems to only affect IOS devices since it's working on an Android device I used to test this feature.
You can test this behaviour on this website scanApp
Currently my IOS version is 17.5.1 (latest at current date)
I tried adding the meta tag:
<meta name="apple-mobile-web-app-capable" content="yes">
But nothing really changed...
Looking forward to a solution :/
Upvotes: -1
Views: 252
Reputation: 145
I was also facing this error. Resetting the settings did it for me. The other answer is talking about hard reset which will remove your data as per my knowledge. So, I won't risk it.
Here's how I solved it (iOS 18 iPhone 15 plus)
It's so inconvenient that even basic things like these require a phone reset. I tried all other things, like resetting the browser data, but none of them worked. But it is what it is. Thankfully this simple fix works instead of the hard reset the other solution says.
Upvotes: 0
Reputation: 1017
Looks like this issue can be fixed by soft resetting your device
To do so follow these steps:
1 - Tap volume up button
2 - Tap volume down button
3 - Long press power button until apple logo shows
This solved the issue for me
Upvotes: 0