Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 3 of 3
  1. #1
    Junior Member
    Join Date
    Dec 2010
    Posts
    14
    Member #
    25639
    I have two divs, one with an image and the other with text. They both use float left so that they are side by side. The issue I am having is that the text doesn't wrap around the image. How do I go about doing this?

  2.  

  3. #2
    Member surfbouy's Avatar
    Join Date
    Dec 2010
    Location
    Noosa, Sunshine Coast, Queensland, Australia
    Posts
    46
    Member #
    25747
    Liked
    3 times
    Hey zooveo,
    if I understand the question properly, you have two divs side by side but you want the one with text to wrap around the one with an image in it..
    as
    <div id="leftDivWithText"></div><div id="picDiv"></div>
    The divs will float side by side.
    to get it inside try.....
    Create your text div and place the pic div inside it as below
    <div id="leftDivWithText"><div id="picDiv"></div></div>
    or
    <div id="leftDivWithText"><img src="yourPic" class="some style including float"/></div>
    if you just want to float the image inside a text box.
    you may also need to add a clearfloat at the bottom to render the design properly.
    Cheers

  4. #3
    Junior Member
    Join Date
    Dec 2010
    Posts
    14
    Member #
    25639
    Thanks for the reply!

    What I ended up doing was:
    HTML Code:
    #image { float: left; width:480px; margin: 0 10px 10px 0px;}
    Basically, I just needed to specify the width so it would wrap properly. Ended up not needing any CSS for the text div.


    oo:


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Search tags for this page

css text wrap with 2 divs
,
css wrap text 2 divs
,
div side by side wrap text
,
how to float two divs and wrap text
,

side by side div text wrap

,
two divs text wrap
,
wrap text around 2 div
,
wrap two div
,
wrap two div text
Click on a term to search for related topics.
All times are GMT -6. The time now is 09:25 AM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com