Keep a jQuery dialog in a div
问题 I am trying to create a number of jQuery dialogs but I would like to constrain their positions to inside a parent div. I am using the following code to create them (on a side note the oppacity option is not working either...): var d= $('<div title="Title goes here"></div>').dialog({ autoOpen: true, closeOnEscape: false, draggable: true, resizable: false, width: dx, height: dy }); d.draggable('option', 'containment', 'parent'); d.draggable('option', 'opacity', 0.45); $('#controlContent')