Page 1 of 1

Block elements next to floating elements

Posted: Sat Jun 12, 2010 10:37 am
by superdezign
Attempting to Google this has been hell, so I've decided to simply ask.

How would one force a block element to end before a floating element? By default, block elements extend as far as they can, causing them to be partially covered by by the floating element. However, a client wants his headers to be in rounded boxes, but wants those rounded boxes to end next to a floating image rather than behind the image. I'm completely stumped as to how I would do this.

Any suggestions?

Re: Block elements next to floating elements

Posted: Sat Jun 12, 2010 3:13 pm
by kaszu
I would use display: inline-block; or float
If it doesn't work, can you post a screenshot or url?