Question: This may be a long shot to do without using JavaScript...

If I have the following (stripped out code for the problem)

```
<div id="container">
    <div id="content"></div>
</div>

```

```css
#container {
    position: relative;
}

#content {
    position: absolute;
}

```

The content box contains dynamic content so a fixed height cannot be used.

Position absolute has to be used on the content div as its using jQuery UI stuff...

How would I get the container box to resize its height to fit the content?

I understand this is probably impossible without using some sort of JavaScript, as placing a div positioned absolute takes it out of the flow etc etc, but just wondered if anyone knew of some sort of work around?

Thanks!

Answer: 
edit: I misunderstood the question the first time.

If all else fails, here's a jQuery solution:

```
$('#container').css('height',$('#content').height());

```
Ok, I have no idea what your content is (jQuery UI stuff). However, say it's just an image: 

```
#container {
    position: relative;
}

#content {
    position: absolute;
    top:0; bottom:0; left:0; right:0;
}

```

This will set your content area to at least 100% width and height of the parent.