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
    Senior Member
    Join Date
    Aug 2011
    Posts
    227
    Member #
    29153
    Liked
    4 times


    When I have too long of a sentence, the second div goes to the bottom.

    For example, if I have:

    <div class = "style1">
    some info
    </div>

    <div class = "style2">
    bunch of info
    </div>

    my styles are set to float:left

    If I have short lines in the second div, they will stay side by side but when I have a long sentence in the second div, it displays below the first div instead of beside it. I do not want my second div to be restricted to a certain width other then the size of the browser window.

  2.  

  3. #2
    WDF Staff mlseim's Avatar
    Join Date
    Apr 2004
    Location
    Cottage Grove, Minnesota
    Posts
    7,715
    Member #
    5580
    Liked
    717 times
    Float the 2nd one right instead of left.


  4. #3
    WDF Staff AlphaMare's Avatar
    Join Date
    Oct 2009
    Location
    Montreal, Canada
    Posts
    4,570
    Member #
    20277
    Liked
    878 times
    Or maybe specify a width as a percentage instead of a pixel measurement.
    If you give each div a width of 50% or less, and clear between them, that should work.
    Good design should never say "Look at me!"
    It should say "Look at this." ~ David Craib


    http://digitalinsite.ca ~ my current site . . info@digitalinsite.ca ~ my email

    If you feel that someone's post helped you fix your problem, answered your question, or just made you feel better, feel free to "Like" their post. The "Like" link is at the bottom right of each post, along side the "reply" link. And if you are being helped here, try to help someone else - pass it on!


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
  •  
All times are GMT -6. The time now is 03:17 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com