Say you have a Div (id="toolbar"
), and inside that toolbar you have a Div (id="ButtonHolder"
) that contains 2 buttons. If you float the #ButtonHolder
to the right and don't set an explicit width on it, is that kosher?
I've read on stack overflow that you should always set a width on a floated element. The buttons text might change, from save to apply, and I don't want to have to adjust #ButtonHolder
's width every time.
I thought about setting #ButtonHolder
's width to auto
, but the browser does that by default so it seems unnecessary to set it's width to auto. I'm worried the browser might not always float #ButtonHolder
the way I think it should.