No replies
Last seen: 12 years 46 weeks ago
Joined: 2007-09-13
Posts: 1
Points: 0

I'm attempting to move to CSS layouts and away from table layouts as much as I can. But I can't figure out how to get an element to use "the rest of the width". Here is what I would do with a table.

Hello World

This gives me a label with a set width and then a text box that fills up the rest of the width of the the table's containing element.

I've tried lots of various combinations of nested divs and spans using various css display values but I can't get the same effect.

I need this because I don't know the width of my containing element but I want to maximize the size of my text box.

I know this is probably one of those "duh", I should have thought of that things but I can't figure it out.