0

I've created a button (named 'quote') in WordPress post editor (TinyMCE) normal mode, and I've been successful in adding some functionality to that button. The question is how can I make this button also appear in the 'full screen mode editor' (also known as Distraction Free Writing Mode).

functions.php:-

add_action('init', 'add_button');  
function add_button() {  
   if ( current_user_can('edit_posts') &&  current_user_can('edit_pages') )  
   {  
     add_filter('mce_external_plugins', 'add_plugin');  
     add_filter('mce_buttons_3', 'register_button');  
   }  
}  
function register_button($buttons) {  
   array_push($buttons, "quote");  
   return $buttons;  
}  
function add_plugin($plugin_array) {  
   $plugin_array['quote'] = get_bloginfo('template_url').'/js/customcodes.js';  
   return $plugin_array;  
}

I've googled and found that I might have to add some sort of filter. WordPress filters out buttons in the Full Mode, so I've to add the button again to the $buttons array. I believe that I'm pretty close to it.

1
  • Better suited for wordpress.stackexchange. I flagged for moderator attention, you should see this question get moved.
    – hakre
    Aug 27, 2013 at 21:11

1 Answer 1

0

You can check this link for your issue. It will help you.

This is the link you are looking for: Enjoy!

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.