Site logo

Archived topic

change the colors of TyniMCE

5 replies · Started by Luis on August 20, 2017

Viewing posts 1–6 of 6

Good afternoon,

How can I change the colors of TyniMCE? What Hooks should I use?

I want to use the function "my_mce_settings" and then "add_filter ('tiny_mce_before_init', 'my_mce_settings'); But I do not know what hooks I have to use of the many there are!

Thank you very much!

Hello,

My code is:

function my_mce_settings( $settings ) {

//limita los colores de texto en TinyMCE para sólo tener algunos colores predefinidos
$custom_colors = '"43a9cf", "Azul", "dfa10d", "Naranja", "be7bd2", "Violeta"';
$settings['textcolor_map'] = '['.$custom_colors.']';

return $settings;
}
add_filter('tiny_mce_before_init', 'my_mce_settings');

And it does not work in wp_head

Thank you very much

Okay. I used Code Snippets before using GP, but I thought GP Hooks did the same thing.
okay. Understood, and will continue using Code Snippets.
Thank you very much for clarifying the subject.

No problem!

This archived topic is closed to new replies.