每当我点击媒体插件时,弹出窗口都会显示,但Type:select列表为空。在我的Javascript控制台中,我看到一个错误,这是屏幕截图:
未捕获TypeError:对象[object Object]没有方法'getElementRule'
代码段位于tinymce / plugins / media / js / media.js中:
getMediaTypeHTML : function(editor) {
function option(media_type, element) {
if (!editor.schema.getElementRule(element || media_type)) {
return '';
}
return '<option value="'+media_type+'">'+tinyMCEPopup.editor.translate("media_dlg."+media_type)+'</option>';
}
我相信我们是Tiny的最新版本之一。
关于我搞砸了什么的任何指导?
这是我的配置:
tinyMCE_GZ.init({
plugins : 'advimage,advlink,table,fullscreen,paste,media,spellchecker,imagemanager,template,insertform',
themes : 'advanced',
languages : 'en',
disk_cache : true,
debug : false
});
tinyMCE.init({
theme : 'advanced',
plugins : 'advimage,advlink,table,fullscreen,paste,media,spellchecker,imagemanager,template,insertform',
mode : 'textareas',
editor_deselector : 'mceNoEditor',
theme_advanced_toolbar_location : 'top',
theme_advanced_toolbar_align : 'center',
theme_advanced_layout_manager : 'SimpleLayout',
theme_advanced_buttons1: 'bold,italic,underline,strikethrough,separator,justifyleft,justifycenter,justifyright,justifyfull,separator,cut,copy,pastetext,pasteword,selectall,separator,spellchecker,styleselect,formatselect',
theme_advanced_buttons2: 'link,unlink,anchor,separator,image,insertimage,media,template,insertform,separator,bullist,numlist,blockquote,outdent,indent,separator,code,separator,removeformat,cleanup,separator,fullscreen',
theme_advanced_buttons3: 'tablecontrols',
apply_source_formatting : true,
valid_elements:
spellchecker_languages : '+English=en',
extended_valid_elements : 'script[src|type],form[action|method|id|class|enctype]',
valid_children : '+body[style]',
theme_advanced_statusbar_location : 'bottom',
theme_advanced_resizing : true,
theme_advanced_resize_horizontal : false,
theme_advanced_blockformats : 'p,h2,h3,h4,h5,h6,div',
external_image_list_url : '/vendor/tinymce/monk/clientImageList.php',
external_link_list_url : '/vendor/tinymce/monk/clientLinkList.php',
media_external_list_url : '/vendor/tinymce/monk/clientVideoList.php',
flash_external_list_url : '/vendor/tinymce/monk/clientFlashList.php',
flash_wmode : 'transparent',
relative_urls : false,
content_css : '/vendor/tinymce/monk/contentCss.php',
template_external_list_url : '/vendor/tinymce/monk/clientMonkletList.php?monklets=true',
template_popup_width : '400',
template_popup_height : '250'
});
我将不胜感激。