so I'm building a voice recorder using JavaScript, and the voice recording works just fine when I run the .html with the script locally, however as soon as I upload it to the server, the .html page displays just fine, but the script no longer works - as in when the button is clicked, there is no prompt to get user's microphone permission or anything.
The webpage I hosted the recorder is notfungi.com.
Appreciate any help!
The problem is that you are using navigator.mediaDevices.getUserMedia
from a non-secure page. So you are getting an error about navigator.mediaDevices being undefined. Check in your developer tools console and you will see the error.
For more details on the security for getUserMedia
follow this link: https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getUserMedia#security