Customize CKeditor and remove h1 from formatting

Permalink
Hi! I like to remove h1 from the format-dropdown in CKeditor. From a SEO and Design perspective our editors should not use two h1 in the content. So removing this from the WYSIWYG editor would help a lot.
Does anyone now how to achieve this in concrete5?

In the documentation from CKeditor I found this description. But where can I do this safely in C5?
http://docs.ckeditor.com/#!/api/CKEDITOR.config-cfg-format_tags...

best Regards, Roland

webpresso
View Replies:
MrKDilkington replied on at Permalink Reply
MrKDilkington
Hi webpresso,

The config settings for CKEditor are in the CkeditorEditor class.
https://github.com/concrete5/concrete5/blob/develop/concrete/src/Edi...

I am not sure if this file can be overridden.
webpresso replied on at Permalink Reply
webpresso
Thanks for your reply (and discussion in slack).

As a designer I have no chance to override this at the moment in a good way without tutorial.
But many thanks for checking this out.

best regards, Roland
bporte replied on at Permalink Reply
Hi,
In ./application/config/generated_overrides/site.php you can put :
return [
'sites' => [
'default' => [
'name' => 'YOUR_SITE',
'editor' => [
'ckeditor4' => [
'custom_config_options' => [
'format_tags' => 'p;h2;h3',
],
],
],
],
],
];
I write from the Controller of my package (see below), but you can write the part of the table manually in a site.php I think.

use Config;
Config::save('site.sites.default.editor.ckeditor4.custom_config_options.format_tags', 'p;h2;h3');

Regards