I have problem with callback at TinyMCE. I am working with TeamSite 6.7.1 SP1.
All settings if working fine but not callbacks. Someone have any ideas how to resolve these problems?
Below code from
custom_config.js
IWTinyMCECustomConfig("custom_line", "theme_advanced_layout_manager",
"SimpleLayout");
IWTinyMCECustomConfig("custom_line", "toolbarRow",
"removeformat,cut,paste,pasteword,code");
IWTinyMCECustomConfig("custom_line", "theme_advanced_path_location",
"none");
function custom_trim(type, value) {
switch (type) {
case "get_from_editor":
alert("Value HTML string: " + value);
// Do custom cleanup code here
break;
case "insert_to_editor":
alert("Value HTML string: " + value);
// Do custom cleanup code here
break;
case "get_from_editor_dom":
alert("Value DOM Element " + value);
// Do custom cleanup code here
break;
case "insert_to_editor_dom":
alert("Value DOM Element: " + value);
// Do custom cleanup code here
break;
}
return value;
}
function myCustomOnChangeHandler(inst) {
alert("Some one modified something");
alert("The HTML is now:" + inst.getBody().innerHTML);
}
IWTinyMCECustomConfig("custom_line", "onchange_callback",
"myCustomOnChangeHandler");
/*
IWTinyMCECustomConfig("custom_line", "cleanup_callback",
"custom_trim");
*/