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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T18:33:53+00:00 2026-05-23T18:33:53+00:00

In Firefox, I am unable to scroll by dragging the scroll bar inside an

  • 0

In Firefox, I am unable to scroll by dragging the scroll bar inside an <a> block:

<a id="monther" class="single" href="">
    <span>Month</span>
    <ul class="month" style="height:100px;width:200px;overflow:auto;">
        <li id="1310421600">Jul 2011</li>
        <li id="1307829600">Jun 2011</li>
        <li id="1305151200">May 2011</li>
        <li id="1302559200">Apr 2011</li>
        <li id="1299884400">Mar 2011</li>
        <li id="1297465200">Feb 2011</li>
        <li id="1294786800">Jan 2011</li>
        <li id="1292108400">Dec 2010</li>
        <li id="1289516400">Nov 2010</li>
    </ul>
</a>

Things of note:

  • This works fine in other browsers I tried
  • If I change the <a> to a <div> it works fine in Firefox as expected
  • I can still scroll using the mousewheel, or by clicking the arrows at either end of the scrollbar (in Firefox)

The reason I am using <a> is because I am binding it’s blur event to hide the <ul>.

  • 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-23T18:33:54+00:00Added an answer on May 23, 2026 at 6:33 pm

    Your document structure is invalid. <ul> is a block-level element, <a> is an inline element; inline elements are not allowed to contain block-level elements, only other inline elements. (Block-level elements may contain either.) That this works in other browsers is an implementation-dependent quirk and you should not count on it continuing to work in the future.

    The proper way to solve this is to make a containing <div> focusable by adding a tabindex attribute:

    <div id="monther" class="single" tabindex="0">
        <span>Month</span>
        <ul class="month" style="height:100px;width:200px;overflow:auto;">
            <li id="1310421600">Jul 2011</li>
            <li id="1307829600">Jun 2011</li>
            <li id="1305151200">May 2011</li>
            <li id="1302559200">Apr 2011</li>
            <li id="1299884400">Mar 2011</li>
            <li id="1297465200">Feb 2011</li>
            <li id="1294786800">Jan 2011</li>
            <li id="1292108400">Dec 2010</li>
            <li id="1289516400">Nov 2010</li>
        </ul>
    </div>
    

    See it in action here. The <ul> hides after the containing <div> loses focus in IE, Chrome, and Firefox.

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

Sidebar

Related Questions

I'm unable to run any selenium tests since I updated Firefox to 3.6. Is
Firefox 3 has introduced a new behavior in which line-height, when unset, differs from
when site's link broken i found that the firefox show me the unable to
How to remove iframe's scrllbars? In Firefox it's easy, however I found myself unable
Could anyone tell me why mozilla firefox unable to display the images where explorer
I am unable to resize a browser window using javascript in Firefox 7. This
Getting the following error when running rspec tests unable to obtain stable firefox connection
I am unable to get document.execCommand('SaveAs', false, /home/prakash/temp/log.html) to work in either Firefox or
Firefox 3.5 does not allow creating java OBJECT tag with Javascript (document.write)? this technique
Firefox requires xhtml extension for mathml but IE will not display pages with xhtml

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.