Show class from css in format dropdown
Array value ‘content_css’ is not enough, TinyMCE can’t simply get the classes from the custom.css file. You need to define the list of styles you want in the dropdown: function my_format_TinyMCE( $in ) { $in[‘content_css’] = get_template_directory_uri() . “/custom.css”; $in[‘importcss_append’] = TRUE; $in[‘style_formats’] = json_encode(array( array(‘title’ => ‘Title for Style #1’, ‘classes’ => ‘example-class’), array(‘title’ … Read more