Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

divs

  • 02-06-2011 01:31AM
    #1
    Registered Users, Registered Users 2 Posts: 210 ✭✭


    hi when i float 2 divs inside a warpper div it stops expanding i have the warpper set to 100% but it stops when i float 2 why would this b? would any one know


Comments

  • Registered Users, Registered Users 2 Posts: 184 ✭✭Razzuh


    Could you copy and post some html and the css?


  • Registered Users, Registered Users 2 Posts: 12,025 ✭✭✭✭Giblet


    You need to clear after the two divs.
    <style>
    .float {
      float:left;
    }
    .clear {
      clear:both;
    }
    </style>
    
    <div class="wrapper">
      <div class="float"></div>
      <div class="float"></div>
      <div class="clear"></div>
    </div>
    


  • Registered Users, Registered Users 2 Posts: 210 ✭✭pjwhite99


    Thanks giblet worked out for me well thanks again


Advertisement