WordPress TinyMCEのスタイルメニューの項目追加

<?phpif ( !function_exists( 'initialize_tinymce_styles' ) ):add_filter('tiny_mce_before_init', 'initialize_tinymce_styles', 10000);function initialize_tinymce_styles($init_array) { $style_formats = array( array( 'title' => '否定', 'inline' => 'span', 'classes' => 'text-negative' ), array( 'title' => '肯定', 'inline' => 'span', 'classes' => 'text-positive' ), array( 'title' => '例示・用語', 'inline' => 'span', 'classes' => 'text-example' ), array( 'title' => '強調', 'inline' => 'strong', 'classes' => 'text-emphasis' ), array( 'title' => '区切り線', 'block' => 'hr', 'classes' => 'hr-divider' ), ); $init_array['style_formats'] = json_encode($style_formats); return $init_array;}endif;