The code below will change TinyMCE’s default class, useful for styling the post editor to look like the front end of your site. This function goes into your theme’s functions.php file.
[php]
function change_editor_body_class($init){
$init[‘body_class’] = ‘my_class’;
return $init;
}
add_filter(‘tiny_mce_before_init’, ‘change_editor_body_class’);
[/php]
If you enjoyed this post, make sure to subscribe to WPMayor’s RSS feed.