var open_win; var field_name; tinyMCE.init({ mode : 'textareas', editor_selector : 'dynasite', theme : 'advanced', language: 'nl', plugins : 'style,table,advlink,advhr,advimage,preview,media,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template,spellchecker', theme_advanced_buttons1: 'preview,fullscreen,|,cut,copy,paste,pastetext,pasteword,|,cleanup,removeformat,|,undo,redo,|,link,unlink,anchor,|,image,media,advhr', theme_advanced_buttons2: 'bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,outdent,indent,sub,sup,|,forecolor,backcolor,|,search,replace', theme_advanced_buttons3: 'styleselect,fontsizeselect,|,table,delete_table,row_props,cell_props,delete_col,delete_row,col_after,col_before,row_after,row_before', theme_advanced_buttons4: 'split_cells,merge_cells,|,visualaid,|,charmap,spellchecker,|,code', theme_advanced_toolbar_location : 'top', theme_advanced_toolbar_align : 'left', theme_advanced_path_location : 'bottom', // The CSS file of the edited content (= same as real CSS file) content_css : '/css/style.generated.css', theme_advanced_styles : 'Koptekst=koptekst;Tussenkop=tussenkop', fix_table_elements : true, spellchecker_languages : 'Dutch=nl', spellchecker_report_mispellings : false, extended_valid_elements : 'hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]', // List of links external_link_list_url : '/tiny_mce/list_links.php', // List of images //external_image_list_url : 'tiny_mce/example_image_list.js', //flash_external_list_url : 'tiny_mce/example_flash_list.js', //media_external_list_url : 'tiny_mce/example_media_list.js', // This function is called when someone presses Browse... file_browser_callback : 'fileBrowserCallBack', theme_advanced_resize_horizontal : false, theme_advanced_resizing : true, nonbreaking_force_tab : true, apply_source_formatting : true }, { mode : 'textareas', editor_selector : 'reaction', theme : 'advanced', language: 'nl', plugins : '', theme_advanced_buttons1: 'bold,italic,underline,separator,bullist,numlist,separator,undo,redo', theme_advanced_buttons2: '', theme_advanced_toolbar_location : 'top', theme_advanced_toolbar_align : 'left', // The CSS file of the edited content (= same as real CSS file) content_css : '/css/style.generated.css', // List of links theme_advanced_resize_horizontal : false, theme_advanced_resizing : false, nonbreaking_force_tab : true, apply_source_formatting : false }); function mce_setValue(field_name, str) { open_win.document.forms[0].elements[field_name].value = str; } function fileBrowserCallBack(field_name, fb_url, fb_type, win) { fb_type = (fb_type == null) ? '' : fb_type; fb_url = (fb_url == null) ? '' : fb_url; open_win = win; // This is where you insert your custom filebrowser logic var oNewWindow = window.open('/tiny_mce/filebrowser/index.php?field_name='+field_name+'&fb_url='+fb_url+'&fb_type='+fb_type, 'name', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,modal=1,width=450,height=600', false); }