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 8822703
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T06:10:14+00:00 2026-06-14T06:10:14+00:00

I have a REALLY BASIC question regarding nested divs and height inheritance. Let’s say

  • 0

I have a REALLY BASIC question regarding nested divs and height inheritance. Let’s say I have the following html snippit:

...
<div style="height: 50px;">
    <div style="height: inherit;">
    </div>
</div>
...

I would think just by inspection that the inner div would have the same height (50px) as the outer one but when I tested it the height was not inherited.

First off, are parent/child relationships betwen divs defined by nesting one within the other? Next, what do I need to do to make the inner div inherit the outer one?

Sorry guys for such a basic question. I am running on fumes here been working (on something else for hours and I have to switch gears to this). Please don’t bash me for asking such a dumb question. 🙂

Thanks!

  • 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-14T06:10:15+00:00Added an answer on June 14, 2026 at 6:10 am

    If you are not able to inherit height of parent div use height: 100%; for inner div

    Demo

    And btw your div does inherit height, it’s just that if you want to see give it a background-color or a border and you’ll see the inner div has inherited the height of it’s parent div

    Demo 2

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have really basic question. How can I get form id by input element
I have a really basic question concerning unix timestamp and mysql date. I'm trying
I realize this question is pretty basic, but I'm really stuck. I have a
I work with python and I have a really basic question. I an array
this is a really basic question - I have a model called Book, which
This is probably a really basic question - but I have a list of
I have a really basic question on SQL. Relational Schema: Student (Sid, Sname )
I have a really very basic doubt regarding STL containers. My requirement is that
Have a really basic question about rails - spent hours looking on the internet
i have a really basic java program just one .java/.class file (.java uncompiled .class

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.