resizable - jquery resisizable not working when wrapInner is used -
i have span nested within jquery resizable div, nested within jquery draggable div.
i using wrapinner add textarea span when span clicked editing purposes.
for reason, resizable not working.
i dont know if missing obvious.
any appreciated
heres jsfiddle http://jsfiddle.net/vxfhd/
and code
<!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <title>untitled document</title> <script src="http://code.jquery.com/jquery-1.9.1.js"></script> <script src="http://code.jquery.com/ui/1.10.1/jquery-ui.js"></script> <script> $(document).on('click', '#span22', function (event) { $('#span22').wrapinner('<textarea style="width:100%; height:100%; background-color:transparent; border:0"/>'); $('span textarea').focus(); var box_id = 22; var page_ref = 170; var template_ref = 15; var mybox = "span" + box_id; $.getjson("get_edit_content.php", { box_id: box_id, page_ref: page_ref, template_ref: template_ref }) .done(function (data) { $('textarea').html(data.a); }); }); $(document).on('blur', 'textarea', function () { $("span").html($('span textarea').val()); var edit_content = $('#span22').html(); var box_id = 22; var page_ref = 170; var template_ref = 15; $.post("update_textarea.php", { box_id: box_id, page_ref: page_ref, template_ref: template_ref, edit_content: edit_content }, function (data, status) {}); }).on('click', 'textarea', function (event) { event.stoppropagation(); }); $(function () { $(".resizable").resizable(); $("#draggable").draggable(); }); </script> </head> <body> <div id="draggable"> <div class="resizable" style="width:300px;height:200px; background:red"> <span id="span22">testing</span> </div> </div> </body> </html>
as answered karthik
i had missed checking jquery ui file in frameworks , extansions
Comments
Post a Comment