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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T09:53:38+00:00 2026-06-15T09:53:38+00:00

I am trying to make content div show a horzontial scroll bar once the

  • 0

I am trying to make content div show a horzontial scroll bar once the page becomes too narrow for the content inside of the content div. Currently, my setup is as follows:

Current Display

HTML:

<div id="LeftNavigation">
    <div id="TopNav">Menu1</div>
    <div id="BottomNav">Menu2</div>
</div>
<div id="ContentContainer">
    <div style="float: left; width: 500px">Content1</div>
    <div style="float: left;">Content2</div>
<div>

CSS:

#LeftNavigation {
    float: left;
}

#TopNav,
#BottomNav {
    width: 165px;
}

#ContentContainer {
    margin-left: 180px;
    min-height: 150px;
    padding: 10px;
}

I’d like to have my page work like the image below. Where my content container has a minimum width of say…600 pixels and then when the page width gets below the combined width of the menu and content(including margins), a scroll bar shows up. I can’t figure out how to get this to work properly, though. My ContentContainer div keeps wrapping below my LeftNavigation div whenever the page becomes too narrow. Thanks in advance.
Desired Display

  • 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-15T09:53:39+00:00Added an answer on June 15, 2026 at 9:53 am

    You need to add a size to ContentContainer and add overflow-x:auto. The scroll bar will show up on ContentContainer, not the entire page as you illustrate.

    If you want it where shown in the diagram you’ll need to make a fake scrollbar and use JavaScript to make it work.

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

Sidebar

Related Questions

I'm trying to make a show/hide content feature work on my page: <div> <div
I am trying to make a div which expands to show hidden content when
I am trying to make an AJAX request that updates a div's content when
I'm trying to make simple website with content background combined from 3 images: top
I am trying to make a webpage so that content will only be visible
I'm trying to make two columns — sidebar and content. Minimum height of each
I'm trying to make a JFrame with a usable content area of exactly 500x500.
I am trying to make a function that returns the content of the webpage
I'm trying to make a specific control smaller, without making its content smaller.. If
Im trying to make the contents of a List thats a dependency property show

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.