我目前正在尝试弄清楚如何将外部脚本加载到 tinymce 中。该脚本是 p7EHCscript,用于根据较大 div 的高度使两个 div 等高。
我需要 p7EHC 脚本能够在 tinymce 编辑器中执行此操作,因此它看起来就像正在创建的最终页面。
我目前使用 tinymce 的设置是:
tinyMCE.init({
// General options
mode : "textareas",
editor_selector : "mceEditor",
editor_deselector : "mceNoEditor",
remove_script_host : false,
convert_urls : false,
content_css : 'http://localhost/tmtphotography/css/mce.css',
width: "1030",
height : "480",
theme : "advanced",
plugins : "safari, pagebreak, style, layer, table, save, advhr, advimage, advlink, emotions, iespell, inlinepopups, insertdatetime, preview, media, searchreplace, print, contextmenu, paste, directionality, fullscreen, noneditable, visualchars, nonbreaking, xhtmlxtras, template,preview",
file_browser_callback : "filebrowser",
// Theme options
theme_advanced_buttons1 : "save,preview,newdocument,|,bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,styleselect,formatselect,fontselect,fontsizeselect",
theme_advanced_buttons2 : "cut,copy,paste,pastetext,pasteword,|,search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,image,cleanup,help,code,|,insertdate,inserttime,preview,|,forecolor,backcolor",
theme_advanced_buttons3 : "tablecontrols,|,hr,removeformat,visualaid,|,sub,sup,|,charmap,emotions,iespell,media,advhr,|,print,|,ltr,rtl,|,fullscreen",
theme_advanced_buttons4 : "insertlayer,moveforward,movebackward,absolute,|,styleprops,spellchecker,|,cite,abbr,acronym,del,ins,attribs,|,visualchars,nonbreaking,template,blockquote,pagebreak,|,insertfile,insertimage,imgae,media,link",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_statusbar_location : "bottom",
theme_advanced_resizing : true,
theme_advanced_font_sizes : "10px,12px,13px,14px,16px,24px",
font_size_style_values : "xx-small,x-small,12pt,medium,large,x-large,xx-large",
// Skin options
skin : "o2k7",
// Example content CSS (should be your site CSS)
});
`
任何有助于理解如何进行此操作的帮助将不胜感激。