} '); $teste->SetJavascript('$(document).ready(function() { //$("#myTags").tagit(); $("#myTags").tagit({ singleField: true, singleFieldNode: $("#mySingleField"), allowSpaces: true, minLength: 1, removeConfirmation: true, tagSource: function( request, response ) { //console.log("1"); $.ajax({ url: "./includes/tags.php", data: { term:request.term }, dataType: "json", success: function( data ) { response( $.map( data, function( item ) { return { label: item.value, value: item.value } })); } }); }}); });'); $teste->SetJavascript('tinymce.init({ selector:".textid", height: 300,