WordPress: Changing the Default Colors of the WordPress HTML Editor

To change the default colors available in the WordPress WYSIWYG editor, simply add the following code to the functions.php file:

// change buttons in WYSWIG post editor, edit color palette
function change_mce_options( $init ) {
$init['theme_advanced_text_colors'] = 'd21268,146c52,82b600,00949b,010080,001c4b';
$init['theme_advanced_more_colors'] = true;
return $init;
}

add_filter('tiny_mce_before_init', 'change_mce_options');