Created
January 11, 2013 22:12
-
-
Save mboynes/4514406 to your computer and use it in GitHub Desktop.
WP & TinyMCE Styles Dropdown
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Customize TinyMCE -- Add styles dropdown and add some custom styles. Selecting the style will add a class to the element. | |
* | |
**/ | |
function my_tinymce_styles( $init ) { | |
$init['theme_advanced_buttons2_add_before'] = 'styleselect'; | |
$init['theme_advanced_styles'] = 'Top Right Inset=insettop,Left Inset=insetleft,Right Inset=insetright'; | |
return $init; | |
} | |
add_filter( 'tiny_mce_before_init', 'my_tinymce_styles' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment