Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    Regular Coder boogily's Avatar
    Join Date
    Jul 2009
    Posts
    275
    Thanks
    18
    Thanked 4 Times in 4 Posts

    *RESOLVED* Div layouts, floats?

    Trying to make 1 div (730px by 480px) to have 4 divs inside, like a grid. Got the menu title top left, links top right, some text bottom left and a pic bottom right. I can't figure out whats wrong with code. Here it is.

    <div id="services" style="position: absolute; left: 1660px; top: 0px; width: 730px; height: 480px;">
    <div class="menutitle">Services</div>
    <div class="mainlinks">Here are my links</div>
    <div id="servContent1" style="margin-top:200px; margin-left:5px; padding:5px; width:450px; height:270px; overflow:auto; background-color:#ddd9cd; border-color:#040403; border-style:solid; border-width:1px; float:left" align="left">some overflowing text.....</div>


    <div id="servContent2" class="img" style="margin-top:200px; padding:5px; width:250px; height:270px; float:left" align="center"><img src="picturewanted.jpg" width="201" height="220" /></div>


    <!-- END: services -->
    </div>

    Classes are:
    .mainlinks {
    height:50px;
    margin-top:20px;
    margin-right:20px;
    color: #FFF;
    float: right;
    font-family: Verdana, Geneva, sans-serif;
    }

    .menutitle {
    height:50px;
    margin-top:20px;
    margin-left:20px;
    font-size: 28px;
    color: #FFF;
    font-weight: bold;
    float: left;
    font-family: Verdana, Geneva, sans-serif;
    }

    div.img img{
    border-color:#FFF;
    border-style:solid;
    border-width:1px;
    }

    I thought I'd have the margins and floats set correctly. I'm sure its a stupid newb mistake, so sorry if it is. I appreciate the help. Link to is
    www.designbyryanboog.com/spa
    Click on products. (obviously website isn't finished yet... )

    Thanks so much for any help
    Last edited by boogily; 01-07-2010 at 01:02 PM.

  • #2
    Regular Coder boogily's Avatar
    Join Date
    Jul 2009
    Posts
    275
    Thanks
    18
    Thanked 4 Times in 4 Posts
    Nevermind. Fixed it. Needed to wrap the top 2 elements in a wrapper div

  • #3
    Regular Coder boogily's Avatar
    Join Date
    Jul 2009
    Posts
    275
    Thanks
    18
    Thanked 4 Times in 4 Posts
    Dont know how to make this appear as "RESOLVED"


  •  

    Posting Permissions

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