I want to disable some key in CK EDITOR.
I am using CKEDITOR 4.0 & I want to disable some shortcuts keys in CKEDITOR.
e.g. help file opens on Alt + 0
In old version Config Available in Source/plugins/keystroks/plugins.js But not availble in new version.
Using config.keystrokes
you can add and remove keystrokes.
From documentation:
// Disable default CTRL + L keystroke which executes link command by default.
config.keystrokes = [
...
[ CKEDITOR.CTRL + 76, null ], // CTRL + L
...
];
Replace the CKEditor.config.keystrokes with an empty array:
CKEDITOR.config.keystrokes = [];
Or CKeditor already offers a hotkey functionality (see the CKeditor documentation). Using this functionality we can bind keystrokes to CKeditor actions. In order to save, the following line should be added:
CKEDITOR.config.keystrokes = ... [ CKEDITOR.CTRL + 83 /*S*/, null ], ...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With