Disable OTRS Rich Text Editor (CKEditor) Right-Click Menu

Dont create your support topics here! No new topics with questions allowed!

Moderator: crythias

Post Reply
OTRS expert
Posts: 159
Joined: 11 Nov 2011, 19:27
OTRS Version?: 3.0.11

Disable OTRS Rich Text Editor (CKEditor) Right-Click Menu

Post by CSL »

We upgraded to OTRS 3.3 recently and the biggest complaint from our users was the CKEditor (rich text editor) right-click context menu.

This overrides the web browser's own right-click menu with CKEditor's copy and paste commands, which has the annoying side-effect of preventing you from using automatic spell checking and corrections in browsers like Firefox.

Being able to quickly spell-check emails that were going out to clients was deemed vital, so I worked around this by editing this file:

Code: Select all

On line 944 in that file it loads all of the plugins that CKEditor will be configured to use, inside the section CKEDITOR.config.plugins=

There are 3 entries that you need to remove from this list in order to disable the right-click context menu:

Code: Select all

'context menu' 'table tools' 'list style'
(the modified line with those plugins removed is below. You can copy and paste this over line 944 if your CKEditor is the same version 4.3, otherwise you're better to manually remove them instead in case the line has changed):

Code: Select all

Once you've deleted those entries from the list of plugins,

Clear OTRS's cache:

Code: Select all

perl /opt/otrs/bin/otrs.DeleteCache.pl
perl /opt/otrs/bin/otrs.LoaderCache.pl -o delete
Restart the web server,
Then try to right click in an editor window (email reply, etc).
Backend: OTRS 3.0.11 RedHat Enterprise Linux 6.2, Apache, MySQL with replication
Frontend: OTRS 3.0.11 RedHat Enterprise Linux 6.2 with SELinux, Apache SSL

OTRS newbie
Posts: 67
Joined: 08 Jan 2015, 17:01
OTRS Version?: 5.0.10
Real Name: Egareg JAOUEN
Company: Elitt

Re: Disable OTRS Rich Text Editor (CKEditor) Right-Click Menu

Post by elitt »

Thank you for this tip !

I fight against aspell because CKeditor has a specific context menu but aspell doesn't work anymore on my server and my agents really need spellchecking...
Your tip let them use the spellchecker embedded in their browser.
OTRS v5.0.10 on Fedora25 with posgreSQL 9.4.9 database

Posts: 10131
Joined: 04 May 2010, 18:38
OTRS Version?: 5.0.x
Location: SouthWest Florida, USA

Re: Disable OTRS Rich Text Editor (CKEditor) Right-Click Menu

Post by crythias »

I'm including CKEditor docs for those who want a simpler (?) option: Hold ctrl key and right-click menu appears.
OTRS 5.0.x (private/testing/public) on Linux with MySQL database. Also on github.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask

OTRS newbie
Posts: 5
Joined: 25 Feb 2016, 09:22
OTRS Version?: OTRS 4.0
Real Name: Jan
Company: zetcom

Re: Disable OTRS Rich Text Editor (CKEditor) Right-Click Menu

Post by janArbeit »

Is it possible to hide the table button from the button list? Because I fear if the ckeditor context menu is disabled somebody won't realize that tables cannot be changed anymore. Maybe somebody starts with a initial table configuration and edits it for a long time and then realizes no more rows can be added, i.e. I would prefer not to allow to add tables at all.

OTRS newbie
Posts: 71
Joined: 02 Feb 2011, 14:45
OTRS Version?: 6.0.12

Re: Disable OTRS Rich Text Editor (CKEditor) Right-Click Menu

Post by tpsupport »

See my post for OTRS 6 and ckeditor 4.7 here: viewtopic.php?f=62&t=26360&p=165069#p165069

To remove the additional Items in the Richtext editor menu I disabled "Frontend::RichText::EnhancedMode" in Sysconfig.
Link to config item:
https://yourserver.com/index.pl?Action= ... hancedMode
OTRS 6 - Ubuntu 16.04 x64, Azure Database for MySQL server 5.7, Perl 5.22.1, Apache/2.4.18

Post Reply