On Custom Post Type generates javascript error:
Uncaught ReferenceError: tinyMCE is not defined
https://www.ads-software.com/extend/plugins/wp-tinymce-excerpt/
]]>This line:
ed.settings.theme_advanced_buttons1 = "bold,italic,underline,seperator,justifyleft,justifycenter,justifyright,separator,link,unlink,seperator,pastetext,pasteword,removeformat,seperator,undo,redo,seperator,spellchecker,";
Should read:
ed.settings.theme_advanced_buttons1 = "bold,italic,underline,separator,justifyleft,justifycenter,justifyright,separator,link,unlink,separator,pastetext,pasteword,removeformat,separator,undo,redo,separator,spellchecker,";
That way the separators will show.
https://www.ads-software.com/extend/plugins/wp-tinymce-excerpt/
]]>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
}
}
https://www.ads-software.com/extend/plugins/wp-tinymce-excerpt/
]]>