WordPress.org

Support

Support » Plugins and Hacks » WP TinyMCE Excerpt » [Plugin: WP TinyMCE Excerpt] Bug fix: making sure it doesn't kill "Custom Fields" plu

[Plugin: WP TinyMCE Excerpt] Bug fix: making sure it doesn't kill "Custom Fields" plu

  • Certain admin pages, such as the popular plugin “custom fields” doesn’t have TinyMCE defined, and still runs the admin_hear-post actions (giving an error, halting the plugin). Fix, wrap it in try/catch:

    function tinymce_excerpt() {
    jQuery(“#excerpt”).addClass(“mceEditor”);
    try {
    tinyMCE.execCommand(“mceAddControl”, false, “excerpt”);
    tinyMCE.onAddEditor.add(function(mgr,ed) {
    if(ed.id==”excerpt”){
    ed.settings.theme_advanced_buttons2 =””;
    ed.settings.theme_advanced_buttons1 = “bold,italic,underline,seperator,justifyleft,justifycenter,justifyright,separator,link,unlink,seperator,pastetext,pasteword,removeformat,seperator,undo,redo,seperator,spellchecker,”;
    }
    });
    }catch() {
    // ignore
    }
    }

    http://wordpress.org/extend/plugins/wp-tinymce-excerpt/

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: WP TinyMCE Excerpt] Bug fix: making sure it doesn't kill "Custom Fields" plu’ is closed to new replies.
Skip to toolbar