Where did you install Firefox from? Help Mozilla uncover 3rd party websites that offer problematic Firefox installation by taking part in our campaign. There will be swag, and you'll be featured in our blog if you manage to report at least 10 valid reports!

搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

Learn More

How can we disable keyboard shortcuts on webpages?

  • 2 回覆
  • 9 有這個問題
  • 1 次檢視
  • 最近回覆由 cor-el

more options

I am using the add-on firemacs, which allows us to edit text with emacs key-bindings.

The problem is: some key-bindings (set by firemacs) are overwritten at several webpages (e.g. Evernote and StackExchange).

For example, Ctrl-b moves normally the text cursor to the previous character in a textarea. But in the textarea at any site of StackExchange, Ctrl-b creates `**strong text**`.

Is it possible to disable keyboard shortcuts without disabling shortcuts for firemacs?

The trivial solution is to disable JavaScript. But I want to know a possibility of other solutions.

I am using the add-on firemacs, which allows us to edit text with emacs key-bindings. The problem is: some key-bindings (set by firemacs) are overwritten at several webpages (e.g. Evernote and StackExchange). For example, Ctrl-b moves normally the text cursor to the previous character in a textarea. But in the textarea at any site of StackExchange, Ctrl-b creates `**strong text**`. Is it possible to disable keyboard shortcuts without disabling shortcuts for firemacs? The trivial solution is to disable JavaScript. But I want to know a possibility of other solutions.

所有回覆 (2)

more options

StackExchange links to a bunch of other sites, so I looked at the superuser.com site. The specific script that creates the interactive features of the editor is http://cdn.sstatic.net/Js/wmd.en.js. It's minified so I can't figure out the call needed to remove the keypress event listener. (Actually, I'm not sure I could figure it out even with the full source, as I don't use jQuery.) Maybe it's a question for StackOverflow?

more options

Note that Firefox has a built-in JavaScript beautifier (Shift+F2: jsb) as one of the commands in the toolbox that makes it easy to inspect such a file in the scratchpad.

由 cor-el 於 修改