Vito De Tullio
Vito De Tullio

Reputation: 2121

access firefox about:config property from a web page

It's possibile to access (in read-only mode) to a value stored in a "about:config" property from an "unprivilegied" (as in: loaded from a http:// ... /something.html) script?

More specifically, I see the next ff (19?) will enable by default the "feature" click-to-play (see here for a description).

Is there a way, programmatically, to know in advance if the flag is true on the browser? We use a custom plugin and need to handle a custom "popup" to instruct the users about the feature and how to whitelist. And no, my users aren't savy enough to recognize the default ff "blocked plugin" logo in the upper right corner of the address bar)

Upvotes: 0

Views: 717

Answers (1)

Georg Fritzsche
Georg Fritzsche

Reputation: 98974

This is not accessible from non-chrome code. Even if it was (say from a extension), you shouldn't depend on it as this may not be the setting that triggers the planned changes.

You can differentiate between the plugin not being installed (see navigator.plugins) and other cases by either

  • regularly testing it's scriptability or
  • having the plugin call into the pages script when it is loaded

... and assume "failed to load or got blocked" based on that.

Upvotes: 1

Related Questions