Search code examples
jqueryparentresizable

jquery Change Child Deminsions to match Parents after resize


I have a parent div with a child div inside. The parent div is using jquery Ui resizable. How can i make the child div inherent the parent div dimensions in real time when parent div is resized.

Here's what i have http://jsfiddle.net/dtxhe/7/

After resize, the child div is not resizing according to it's parent.


Solution

  • You can also use this :

    http://jsfiddle.net/dtxhe/11/

    Code :

    $("#container").resizable({ alsoResize: '#child' });