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

  • Home
  • SEARCH
  • 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 6870799
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T03:43:40+00:00 2026-05-27T03:43:40+00:00

I have #maindiv and i am putting divs in that programmatically. So i never

  • 0

I have #maindiv and i am putting divs in that programmatically. So i never know how much inner div will be inside #maindiv. every inner div has width: 160px. I used this css for #maindiv:

 #maindiv
 {
   overflow: auto;
   width: 640px; 
   height: 65px;
   background:lightblue;
 } 

I want #maindiv to make horizontal scroller when total of innerdivs width is more than 160px. My css is not giving me right results. I am not getting any horizontal scroller even i fixed the width of the div. If i have innerdivs with more width that #maindiv then they make #maindiv wider. I even used max-width:160px for #maindiv as well. any Idea? Thanks in advance.

  • 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-27T03:43:40+00:00Added an answer on May 27, 2026 at 3:43 am

    You could try using

    overflow-y: scroll;
    

    See http://jsfiddle.net/4CCfy/

    • 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 on my page that has the attribute align=center ,
I have a parent div called main. It has a bunch of child divs
I have a div which contain other tags inside it <div id=mainDiv> <div> <table>
I have a parent div with a fixed position and inside of that div
Let's say that I have a div that is called mainDiv, and it contains
I have a list of div pairs: MainDiv's and infPanel Divs. I need to
suppose i have what i want is inside maindiv i want to count no
I have a div (main div) which contains several div elements(sub divs). I want
I have a div <div id=maindiv></div> and some checkboxes to add some html element
i have the following scenary: <div class=maindiv> <div class=msg>some text</div> ... <div class=msg>some other

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.