Tiny_Mce编辑器设置图片绝对路径获取当前编辑器

初始化编辑器的内容:

tinyMCE.init({
    mode : "specific_textareas",
    elements : "compContent2,compContent_txt",
    theme : "advanced",
    language : "zh",
    plugins : "safari,pagebreak,style,layer,table,advhr,advimage,advlink,emotions,iespell,inlinepopups,insertdatetime,preview,media,profile,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras",
    content_css : "/tiny_mce/css/content.css",
    template_external_list_url : "/tiny_mce/lists/template_list.js",
    external_link_list_url : "/tiny_mce/lists/link_list.js",
    external_image_list_url : "/tiny_mce/lists/image_list.js",
    media_external_list_url : "/tiny_mce/lists/media_list.js",
    relative_urls : false,
  remove_script_host : false,
  auto_reset_designmode : true
    });

 

获取当前编辑器:

var editor = tinyMCE.activeEditor;

 

设置编辑器属性:

tinyMCE.getInstanceById("compContent__txt").settings.relative_urls = false;

 

你可能感兴趣的:(css,Safari,tinymce)