2011-10-19 6 views
3

TinyMCEを使用しているときにtable toolsを有効にしようとしました。私は私の設定にtabletoolsを追加するときしかし、 '空' ボタンのセットを参照、表示: enter image description hereTinyMCEでテーブルツールを入手する

(右上)

これはコードです:

$('.tinymce').tinymce({ 
script_url : 'js/tinymce/tiny_mce.js', 
content_css : 'css/tinymce.css', 
language : "en", 
mode : "textareas", 
theme : "advanced", 
skin : "o2k7", 
fix_list_elements : true, 
verify_css_classes:true, 
plugins : "paste,fullscreen,table", 
theme_advanced_buttons1 : "bold,italic,underline,strikethrough,|,undo,redo,|,justifyleft,justifycenter,justifyright,justifyfull,|,bul list,numlist,formatselect,fontselect,tablecontrols", 
theme_advanced_buttons2 : "cut,copy,paste,pasteword,|,outdent,indent,blockquote,|,link,unlink,anchor,InsertImageBtn,cleanup,|,forecol or,backcolor,hr,removeformat,sub,sup,|,charmap,emotions,iespell,media,advhr,|,fullscreen", 
theme_advanced_buttons3 : "", 
theme_advanced_toolbar_location : "top", 
theme_advanced_toolbar_align : "left", 
valid_elements : "img[src|alt|title],a[href|target|title],-p,strong/b,em/i,-ul,-ol,-li,-table[!border:1|!cellspacing:0|!cellpadding:5 ],th,-tr,td,p[class],span[class]", 
paste_auto_cleanup_on_paste : true, 
fix_table_elements : true, 
plugins : "-insert", 
width:750, 
height:500 
}); 

テーブルプラグインがプラグインフォルダに存在する場合、javascriptエラーは一切発生せず、最新のTinyMCEバージョンをインストールしました。何が起きているのか?

+0

+1ファイヤーバグを使って「ボタン」を調べましたか? – Thariama

+0

@ Thariama:ちょうどそれらをチェックアウトしました。彼らはセパレータであり、ボタン自体ではありません。 –

答えて

2

問題は、設定に2つのプラグイン要素があることです。 2番目のバージョン:

plugins : "-insert", 

...が最初に上書きされているため、ローカルの「挿入」プラグインのみを読み込みます。両方のリストを1つのconfig要素にまとめることができ、正しく動作するはずです。

+0

+1それを逃した – Thariama

関連する問題