I had a code snippet which would help me to add some custom color to the visual editor text color dropdown along with the default colors. I'm pasting the snippet below.
function change_mce_options( $init ) {
$default_colours = '000000,993300,333300,003300,003366,000080,333399,333333,800000,FF6600,808000,008000,008080,0000FF,666699,808080,FF0000,FF9900,99CC00,339966,33CCCC,3366FF,800080,999999,FF00FF,FFCC00,FFFF00,00FF00,00FFFF,00CCFF,993366,C0C0C0,FF99CC,FFCC99,FFFF99,CCFFCC,CCFFFF,99CCFF,CC99FF,FFFFFF';
$custom_colours = 'e14d43,d83131,ed1c24,f99b1c,50b848,00a859,00aae7,282828';
$init['theme_advanced_text_colors'] = $default_colours . ',' . $custom_colours;
$init['theme_advanced_more_colors'] = true;
return $init;
}
add_filter('tiny_mce_before_init', 'change_mce_options');
After wordpress 3.9 update it stopped working, I've tried a lot to fix it, but I am unable to do it, can you please help me out?
theme_advanced_text_colors
all they were saying is how to add new buttons. But mine is totally different. Hope you understand.