Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Open chrome://settings from a standard webpage [duplicate]

I'm using getUserMedia to access the visitor's webcam, but if the visitor denies access, they will never be asked again.

Detecting that is easy enough (access is denied almost instantly when requested). So when it is blocked, I want to direct the user to chrome://settings/contentExceptions#media-stream so that they can change the setting (I'll be using browser detection to tailor this link for each browser). But a simple link makes Chrome unhappy:

Not allowed to load local resource: chrome://settings/contentExceptions#media-stream

I've also tried various JavaScript-based methods with the same result, and found several sources on the internet quoting chrome.tabs.create as an option for extensions (but this isn't an extension so chrome.tabs isn't available).

I have 2 questions. The first is simple curiosity; why is this blocked? (what would the risk be from allowing it?). And the main question is: can I get around this restriction?

like image 964
Dave Avatar asked Aug 20 '13 14:08

Dave


People also ask

How do I open Chrome settings?

You can open the Settings page by clicking on the icon with three stacked horizontal lines to the left of the address bar; this will open up a dropdown menu, and Settings will be located to the bottom of the screen.

How do I open Advanced settings in Chrome?

To access Chrome's advanced settings, click on the three dots and select Settings from the menu and select the Advanced option on the left sidebar. The section will expand to reveal the advanced settings.


2 Answers

You can't nor should you. Instead, instruct the user what those settings are and what he needs to do to change them.

A simple click left of the address bar (in the omnibar of Chrome) can be used to change that setting as well.

https://support.google.com/chrome/answer/95617?hl=en

enter image description here

like image 145
MarZab Avatar answered Sep 20 '22 10:09

MarZab


For security reasons, you can't do this.

Chrome doesn't want to let websites trick inexperienced users into changing Chrome settings.

like image 32
SLaks Avatar answered Sep 18 '22 10:09

SLaks