What would be the cleanest way to customize the editor for Wysiwyg field ?
Permalink Browser Info Environment
Hi,
I would like to customize the WYSIWYG editor - mainly I would like to remove plugin to enable only a subset of the functionalities of CKeditor that make sense in the context of the block I'm creating. What would be the cleanest and most maintainable way to do that in your addon ?
I would like to customize the WYSIWYG editor - mainly I would like to remove plugin to enable only a subset of the functionalities of CKeditor that make sense in the context of the block I'm creating. What would be the cleanest and most maintainable way to do that in your addon ?
Type: | Discussion |
---|---|
Status: | Resolved |
Yes, that's exactly that.
I have already customized CKEditor sitewide for full page rendition of rich text.
But I have smaller blocs created with your addon where it only makes sense to allow inline HTML elements in rich text - so italic, bold and links.
I could instruct editors not to include gigantic images and h2 level elements in a 350x350 bloc, but we all know they will eventually do that if they can ;)
I have already customized CKEditor sitewide for full page rendition of rich text.
But I have smaller blocs created with your addon where it only makes sense to allow inline HTML elements in rich text - so italic, bold and links.
I could instruct editors not to include gigantic images and h2 level elements in a 350x350 bloc, but we all know they will eventually do that if they can ;)
Yeah, understand that editors could go wild whenever they can. I will have to put it on my backlog, there's currently so much other stuff going on and it's not small enough to pick up straight away unfortunately.
Not sure how advanced with coding you are yourself, but I am also open to edits from users (instead of it being a one-man-project forever haha).
Kind regards,
Ramon
Not sure how advanced with coding you are yourself, but I am also open to edits from users (instead of it being a one-man-project forever haha).
Kind regards,
Ramon
I will probably look into updating it myself - the problem as always is lack of time ;) It does seem you can override across packages, I did not know you could do that ! I have to look into that, that would be pretty neat...
Hi ! I made the update. Usage is as follow. I could not figure out how to override a PHP class from one package in another. Maybe you could add the small change to future releases. I could send you the code, it seems I'm not allowed to insert PHP files here...
"summary" => [ "type" => "Wysiwyg", "label" => t("Résumé"), "config" => [ "exclude_plugins" => [ 'blockquote', 'font', 'format', 'horizontalrule', 'image', 'image2', 'indentblock', 'indentlist', 'justify', 'list', 'liststyle', 'pasteFromWord', 'stylescombo', 'table', 'tableresize', 'tableselection', 'tabletools', 'concrete5uploadimage', 'concrete5styles', '' ], ], ],
If you still have this code, let me know. Would be happy to implement this if you have it all ready and functional!
Kind regards
Ramon
Kind regards
Ramon
Hi. I still have the code, I juste have to locate it in the right project ;) Where can I send it ?
You can send it by PM. If it doesn't allow .php, do it as a .txt!
I found back the files, it's just a simple modification. However, I don't seem to find private messages anymore on the update forum ?!
Just released version 1.4.0 that includes this functionality!
Kind regards
Ramon
Kind regards
Ramon
This currently is not possible. I suspect you want to be able to, let's say, just enable bold/italic/underline and also maybe have the in a specific order?
Kind regards,
Ramon