I have the following HTML-code:
<div style="width:100%">
<div id="div1" style="float:left">
<img src="http://www.lappelducourty.be/test/wp-content/uploads/2013/01/siesta-300x225.jpg">
</div>
<div id="div2" style="float:left">
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. In vitae libero lectus, varius placerat risus. Pellentesque condimentum dapibus fermentum. Nam eget magna nisl, a iaculis massa. Sed congue ultrices felis sed volutpat. Donec tristique ullamcorper ullamcorper. </p>
</div>
</div>
So I have two divs, div1 and div2
The problem is the paragraph is too long so the div is pushed down. I want div2 to stay next to div1 on a normal screen (when the screensize is big enough). If the screen is too small (like on a mobile phone), div2 shoud go to the next line.
Isn't it possible that the width of the paragraph is limited to the width of its parent div, so div2 is still next to div1?
Btw, I don't want to set a (max-)width for the divs...
Thanks a lot!!
Wannes