How to add function buttons to editor toolbar?

Have a great idea for extending Zimbra? Share ideas, ask questions, contribute, and get feedback.
Post Reply
berhab
Posts: 1
Joined: Fri Feb 12, 2021 11:29 am

How to add function buttons to editor toolbar?

Post by berhab »

For composing HTML mails, I would like to add function buttons to the HTML editor, such as source code view (code), Paste from Text, Paste from Word, or undo/redo.
In Zimbra\Zimbra Desktop\jetty\webapps\zimbra\js\, I have identified the following locations where tinymce buttons are configured:

Startup2_all.js
zimbraMail\share\view\htmlEditor\ZmAdvancedHtmlEditor.js
zimbraMail\docs\view\ZmDocsEditView.js
Docs_all.js
NewWindow_2_all.js

Adding there, e.g., the "paste" plugin and the "pastetext" button doesn't seem having any effect.

How to do the appropriate changes to add and display function buttons?

[Additional remark: I have a similar request concerning the web client: I would like to use "Paste Text" and "Paste from Word" in the web client. I saw that Startup2_all.zgz is delivered to my browser, which contains tinymce initialization, including the paste plugin and pastetext button. The button is not displayed when using the advanced (ajax) client type (our default), but is displayed when using the standard (HTML) client type. Is there a way to also display the button in the advanced client type?]
User avatar
jholder
Ambassador
Ambassador
Posts: 4824
Joined: Fri Sep 12, 2014 10:00 pm

Re: How to add function buttons to editor toolbar?

Post by jholder »

You should not edit the files directly. It won't survive an update.

go to wiki.zimbra.com it has guides on how to do this for the classic and new modern UI.
Post Reply