views:

68

answers:

3

Hello,

I am trying to use the alsoResize option. It works when I write this:

$(obj).resizable({ minHeight: 150, minWidth: 280, alsoResize: '.tab_content'});

but the problem is that it's resizing all 'tab_content' elements in the page. I want it to be relative to 'obj' which also contains a 'tab_content', I tried: alsoResize: $('.tab_content',obj) but it didn't work, any suggestions, Thanks

A: 

Can you give an ID to the tab_content object and pass that in as an argument?

adrianos
I am using it inside a plugin that I wrote. The plugin is attached to a window I created that contains tabs inside.The plugin binds the 'resizable' to the window, and I want to also resize the tab content when the window is resized
Anat
A: 

I haven't used resizable before, but I would try something like:

$(obj).resizable({ minHeight: 150, minWidth: 280, alsoResize: $(this).children('.tab_content')});
rosscj2533
A: 

My suggestion would be

var tab_content=$('.tab_content', obj);
console.log(tab_content.length);

//if all is well
$(obj).resizable({minHeight: 150, minWidth: 150, alsoResize:tab_content});
czarchaic