rendered paste body<script type="text/javascript">// Creates a new plugin class and a custom listboxtinymce.create('tinymce.plugins.ExamplePlugin', { createControl: function(n, cm) { switch (n) { case 'participants': var partlb = cm.createListBox('participants', { title : 'Participants', onselect : function(v) { //tinyMCE.activeEditor.windowManager.alert('Value selected:' + v); tinyMCE.activeEditor.focus(); tinyMCE.activeEditor.selection.setContent(v); } }); <?php getTinyPartField() ; ?> return partlb; case 'pages': var pageslb = cm.createListBox('pages', { title : 'Pages', onselect : function(v) { //tinyMCE.activeEditor.windowManager.alert('Value selected:' + v); tinyMCE.activeEditor.focus(); tinyMCE.activeEditor.selection.setContent(v); } }); <?php getTinyPages() ; ?> // Return the new listbox instance return pageslb; } return null; }});tinymce.PluginManager.add('example', tinymce.plugins.ExamplePlugin); tinyMCE.init({ mode : "exact", elements : "html", plugins : '-example', theme : "advanced", theme_advanced_buttons1 : "save,newdocument,|,bold,italic,underline,|,justifyleft,justifycenter,justifyright,justifyfull", theme_advanced_buttons2 : "cut,copy,paste,pastetext,pasteword,|,undo,redo,|,link,unlink,anchor,image,cleanup,help,code,|,forecolor,backcolor", theme_advanced_buttons3 : "participants,pages", theme_advanced_toolbar_location : "top", theme_advanced_statusbar_location : "bottom", theme_advanced_resizing : true, setup : function(ed) { // Add a custom button ed.addButton('mybutton', { title : 'My button', onclick : function() { // Add you own code to execute something on click ed.focus(); ed.selection.setContent('<strong>Hello world!</strong>'); } }); } }); </script>