daily pastebin goal
87%
SHARE
TWEET

Untitled

a guest Sep 14th, 2018 61 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function my_mce_buttons_2( $buttons ) {
  2.     array_unshift( $buttons, 'styleselect' );
  3.     return $buttons;
  4. }
  5. add_filter( 'mce_buttons_2', 'my_mce_buttons_2' );
  6. function my_mce_before_init_insert_formats( $init_array ) {
  7.     $style_formats = array(
  8.         array(
  9.             'title' => '2-spaltig',
  10.             'classes' => 'format-columns',
  11.             'wrapper' => true,
  12.             'block' => 'div'
  13.         )
  14.     );
  15.     $init_array['style_formats'] = json_encode( $style_formats );
  16.     return $init_array;
  17. }
  18. add_filter( 'tiny_mce_before_init', 'my_mce_before_init_insert_formats' );
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top