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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T06:32:11+00:00 2026-05-20T06:32:11+00:00

I have a very weird problem. This ONLY affects Firefox on Mac, using the

  • 0

I have a very weird problem. This ONLY affects Firefox on Mac, using the trackpad (so far as I know), but inside the div that is supposed to be horizontal scrolling only, you are able to scroll vertically too. There seems to be some extra “padding” below the 2nd “container” div which you can see if you change “height” to “min-height” in .container (this will show up on all browsers). All I’m trying to accomplish is to have multi-layered divs (the colored stack in the 2nd container div) “stack” on top of each other, using position: relative, but it seems to create extra, unwanted “padding” that I’m unable to get rid of. Both Chrome and IE do not exhibit this behavior.

<style>    
#scrolling_div {
    border:2px solid black;
    clear:both;
    float:left;
    overflow-x:auto;
    overflow-y:hidden;
    width:400px;
}

.container { border:1px dotted black;height:150px;margin:5px }
.other { width:100px }
#stack1,#stack2,#stack3 { height:150px;width:100px; }
#stack1 { background-color:red;top:-300px;margin-left:60px;position:relative;z-index:1 }
#stack2 { background-color:green;top:-150px;margin-left:30px;position:relative;z-index:2 }
#stack3 { background-color:blue;top:0px;margin-left:0px;position:relative;z-index:3 }
</style>

<div style='float:left;clear:right'>some text</div>
<div id='scrolling_div'>
<table>
    <tr>
        <td>
            <div class="container"><div class="other">test</div></div>
        </td>
        <td>
            <div class="container">
                <div id="stack3"><div style='margin-left:90px'>3</div></div>
                <div id="stack2"><div style='margin-left:90px'>2</div></div>
                <div id="stack1"><div style='margin-left:90px'>1</div></div>
            </div>
        </td>
        <td>
            <div class="container"><div class="other">test</div></div>
        </td>
        <td>
            <div class="container"><div class="other">test</div></div>
        </td>
        <td>
            <div class="container"><div class="other">test</div></div>
        </td>
    </tr>
</table>
</div>
<div style='float:left;clear:left'>some text</div>

Or you can play with the code here: http://jsfiddle.net/bAzND/

  • 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-20T06:32:12+00:00Added an answer on May 20, 2026 at 6:32 am

    I think I found the solution to my dilemma. In case anyone else runs into this issue in the future, the solution was to change all the “stack” divs from position:relative to position:absolute, remove the top attributes, then add style='position:relative;width:160px' to the .container <div> of the stack. The width must be a fixed value.

    Here is the code:

    <style>    
    #scrolling_div {
        border:2px solid black;
        clear:both;
        float:left;
        overflow-x:auto;
        overflow-y:hidden;
        width:400px;
    }
    
    .container { border:1px dotted black;height:150px;margin:5px }
    .other { width:100px }
    #stack1,#stack2,#stack3 { height:150px;width:100px; }
    #stack1 { background-color:red;margin-left:60px;position:absolute;z-index:1 }
    #stack2 { background-color:green;margin-left:30px;position:absolute;z-index:2 }
    #stack3 { background-color:blue;margin-top:0px;margin-left:0px;position:absolute;z-index:3 }
    </style>
    
    
    <div style='float:left;clear:right'>some text</div>
    <div id='scrolling_div'>
    <table>
        <tr>
            <td>
                <div class="container"><div class="other">test</div></div>
            </td>
            <td>
                <div class="container" style='position:relative;width:160px'>
                    <div id="stack3"><div style='margin-left:90px'>3</div></div>
                    <div id="stack2"><div style='margin-left:90px'>2</div></div>
                    <div id="stack1"><div style='margin-left:90px'>1</div></div>
                </div>
            </td>
            <td>
                <div class="container"><div class="other">test</div></div>
            </td>
            <td>
                <div class="container"><div class="other">test</div></div>
            </td>
            <td>
                <div class="container"><div class="other">test</div></div>
            </td>
        </tr>
    </table>
    </div>
    <div style='float:left;clear:left'>some text</div>
    

    Here is the fixed code example: http://jsfiddle.net/ChSfE/

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

Sidebar

Related Questions

i know this question was asked before but i have this very weird beginner
I have a very weird problem in Firefox ( version 3.5.2), and I am
I have a very weird problem: sometimes when I call nHibernate update to an
I have a very weird problem, when storing my session in Memcached. From time
I have a very weird problem.. I really do hope someone has an answer
I got a weird problem. I have a program that (does many things but
I have seen some very weird for loops when reading other people's code. I
We have very strange problem, one of our applications is continually querying server by
I have very little experience building software for Windows, and zero experience using the
i have very simple problem. I need to create model, that represent element of

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.