GeekedOut
GeekedOut

Reputation: 17185

How can I make a taller div wrap around the shorter div on the bottom of the shorter div?

I have this test page: http://www.problemio.com/problems/problem_dev.php?problem_id=225

and I am trying to have the small square ad appear on the left below the person't name. And have the text appear on the right of it.

But when the ad ends, I want to make it so that the body of the text extends to the area below the ad. Is that possible to accomplish with the layout I have on that page currently?

What would I have to adjust?

Thanks!

ps - I know I am using inline css, but its just for testing.

Upvotes: 0

Views: 128

Answers (2)

Bluest_Cube
Bluest_Cube

Reputation: 98

Give this div <div style="float: left; width: 410px;"> that contains the text a value of display:inline; only, so you want to remove the float and width properties.

Also, you have specified a height on the <ins> tags you can change that to height:auto;

Upvotes: 1

mikevoermans
mikevoermans

Reputation: 4007

You have too many divs in there. An image with float: left on it and then just add in the text next to it. It will naturally start wrapping under the image then.

Upvotes: 1

Related Questions