Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9012809
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T03:05:57+00:00 2026-06-16T03:05:57+00:00

I have multiple div tags: The main div that holds the content, if the

  • 0

I have multiple div tags:

The main div that holds the content, if the content gets bigger, the height will obviously get bigger too, but the other divs don’t.

How do I make the other divs take the main div’s height?

Code

<div id="container">
    <span id="header">Fiction Tools</span>
    <span id="paragraph">Lots of text will be in this text box, 
    describing in great detail the awesomeness of Fiction Tools 
    and it’s capabilities. Fiction Tools is known for lots of 
    awesome things, here are a few:</span>
    <ul id="lists">
        <li>We have this awesome design made by Driptone.</li>
        <li>Did I mention, the design is awesome? Well, it is.</li>
        <li>You should be reading this in the voice of Morgan Freeman.</li>
        <li>In a galaxy, far, far away...</li>
    </ul>
    <span id="secondparagraph">Be sure to check out our latest 
    deals which can be found on our Twitter and Facebook profiles 
    for more updates! For any other updates, you can look at our 
    news feed to the right of your screen or tablet.</span>
    <br />
    <div id="first"></div>
    <div id="second"></div>
</div>

CSS

#container {
    border: 1px solid #aaa;
    width: 768px;
    min-height: 200px;
    background: white;
    position: absolute;
}

#first{
    border: 1px solid #aaa;
    width: 768px;
    min-height: 200px;
    background: white;
    position: absolute;
    top: 3px;
    left: 3px; 
    z-index:-1;
}

#second{
    border: 1px solid #aaa;
    width: 768px;
    min-height: 200px;
    background: white;
    position: absolute;
    top: 6px;
    left: 6px;
    z-index: -2;
}

#header {
    position: relative;
    font-size: 24px;
    font-weight: bold;
    color: #404040;
    padding: 25px;
    top: 15px;
}

#paragraph {
    position: relative;
    font-size: 12px;
    color: #8f8f8f;
    padding-left: 25px;
    padding-top: 20px;
    display: block;
}

#secondparagraph {
    position: relative;
    font-size: 12px;
    color: #8f8f8f;
    padding-left: 25px;
    padding-top: 7px;
    display: block;
}

#lists {
    position: relative;
    padding-left: 25px;
    padding-top: 10px;
}

Currently it looks like this:

Current layout

As you see the div that holds the content gets the height, but the others don’t.
Any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T03:05:59+00:00Added an answer on June 16, 2026 at 3:05 am

    Did you try making the height 100%:

    http://jsfiddle.net/egjUZ/

    #first{
            border: 1px solid #aaa;
        width: 768px;
        min-height: 200px;
        background: white;
        position: absolute;
        top: 3px;
        left: 3px; 
        z-index:-1;
        height: 100%;
    }
    #second{
        border: 1px solid #aaa;
        width: 768px;
        min-height: 200px;
        background: white;
        position: absolute;
        top: 6px;
        left: 6px;
        z-index:-2;
        height: 100%
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i have a main div with multiple divs and a tags and i wanted
I'm trying to have JQuery change the content of div tags so that it
I have a main Div tag with multiple div tags as below. The child
I have multiple menues on my page... <div class=menu> <div>Menu header</div> <div>Menu content</div>// should
I am using multiple DIV tags with the same content to create one visible
I need get multiple values from span tags using php, for example : <div>
I have multiple div's on my page, that can be added to the page
I have multiple div's with the same class that are on a page that
My example: I have a View that presents a set of div tags that
I have an iframe with multiple div tags. I have no control over the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.