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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T05:04:25+00:00 2026-05-12T05:04:25+00:00

I have 2 divs, a main content section and a sidebar. What I want

  • 0

I have 2 divs, a main content section and a sidebar.

What I want to happen is force each div to be the same height as the tallest div

If the Sidebar Content is taller then the Main Content I want to push the Main Content down to match the Sidebar Content’s height

+--------------------+----------+
|  Main Content      | Sidebar  |
|                    |          |
|                    |          |
|                    |          |
|                    |          |
|  END               |          |
| __________________ |          |
|                    |          |
|                    |          |
|                    |  END     |
|                    | ________ |
+--------------------+----------+

Conversely, if the Main Content is taller then the Sidebar Content I want to push the Sidebar Content down to match the Main Content’s height

+--------------------+----------+
|  Main Content      | Sidebar  |
|                    |          |
|                    |          |
|                    |          |
|                    |          |
|                    |  END     |
|                    | ________ |
|                    |          |
|                    |          |
|  END               |          |
| __________________ |          |
+--------------------+----------+    

So it would look like this:

+--------------------+----------+
|  Main Content      | Sidebar  |
|                    |          |
|                    |          |
|                    |          |
|                    |          |
|                    |          |
|                    |          |
|                    |          |
|                    |          |
|   END              |  END     |
| __________________ | ________ |
+--------------------+----------+
  • 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-05-12T05:04:25+00:00Added an answer on May 12, 2026 at 5:04 am

    What you want is equal height columns, which can be accomplished with CSS only, without any javascript.

    There are other ways to do this, including jQuery. See this stackoverflow question for more information.

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

Sidebar

Related Questions

Say I have the following DIVs: <div id=top>Page header</div> <div id=main>Main content</div> <div id=sidebar>Sidebar
I have multiple elements each has a short and main divs. I want to
I have three divs : <div id=login /> <div id=content /> <div id=menu />
I have three DIVs, something like this: <div id=header> ... </div> <div id=content> <div
page: http://jsbin.com/eniva4/edit I have one main div: #main-content which contains two div's : #announcement
I have the following layout: <div id=content> <div id=img><img src=></div> <div id=main>Some content</div> <div
I have 3 divs with 2 possible image tags for each (active or inactive).
I keep finding that if I have nested divs inside each other, and one
I have a set of divs that I want to make collapsible/expandable using jQuery's
I have these nested divs and I need the main container to expand (in

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.