javascript - Draggable Element Disappears After Dialog -


i'm trying use draggable/sortable effect add new element list , open dialog window asking name it. happens though after dialog closes newly created element disappears.

$(function() {   $( "#sortable" ).sortable({     revert: true   });   $( "#draggable" ).draggable({     connecttosortable: "#sortable",     helper: "clone",     revert: "invalid",     stop: function(event, ui) {       $("#dialog").dialog('open');     }   });   $( "ul, li" ).disableselection(); }); $(function() {   $("#dialog").dialog({     autoopen: false,     height: 150,     width: 200,     modal: true   }); }); function changetitle() {   var boxtext = $("#newstitle").val();   $(".ui-draggable").text(boxtext);   $(".ui-state-default").removeclass('ui-draggable'); } 

i think i've narrowed down having when dialog returns. ideas?


Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -