> In IE6 I can force a DIV to automatically size to the width of its
> contents by setting its width to 1px. This doesn't work in IE7, it tries
> to render the DIV at the specified width, cutting off its contents. If I
> remove the width entirely, the DIV goes to 100% of the screen width. Will
> I not be able to have any shrink-to-fit DIV's in IE7?
Are you doing it like this: ?
<div style="width:auto;">

Signature
Mark Rae
ASP.NET MVP
http://www.markrae.net
PJ6 - 14 Sep 2007 14:54 GMT
> Are you doing it like this: ?
>
> <div style="width:auto;">
width:auto causes the DIV to size to 100% of the page
Paul
PJ6 - 14 Sep 2007 15:03 GMT
>> Are you doing it like this: ?
>>
>> <div style="width:auto;">
>
> width:auto causes the DIV to size to 100% of the page
Never mind, I foudn the problem. I had a buried element within the DIV that
was 100% width.
Thanks,
Paul