新版本的webrtc使用需要Https,但是在内网开发调试时,要配置Https环境比较麻烦,下面的方法是教你如何在http下使用webrtc

1,点桌面上的Chrome图票,右键->属性,把目票输入框中的内容换成以下内容

"C:\Users\Administrator\AppData\Local\Google\Chrome\Application\chrome.exe" 
--unsafely-treat-insecure-origin-as-secure="http://ip:port" --user-data-dir=本地目录

把字符串中的ip:port换成你自己的服务器的ip加端口,本地目录换成你自己本地一个文件夹

如何在没有https环境下使用webrtc

2,再重启chrome就可以了

如何在没有https环境下使用webrtc

 

相关文章:

  • 2022-01-06
  • 2021-08-21
  • 2022-01-05
  • 2021-12-07
  • 2021-06-23
  • 2022-12-23
猜你喜欢
  • 2021-04-18
  • 2021-06-16
  • 2021-10-30
  • 2021-10-28
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案