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

The Archive Base Latest Questions

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

The html is like this: <div class=a_list> <div class=hide_list_scrollbar></div> </div> <div class=a_list> <div class=hide_list_scrollbar></div>

  • 0

The html is like this:

<div class="a_list">
  <div class="hide_list_scrollbar"></div>
</div>
<div class="a_list">
  <div class="hide_list_scrollbar"></div>
</div>

The js is like this:

$(".a_list").mouseenter(
    function(){
        $(".hide_list_scrollbar").hide();
    }
);
$(".a_list").mouseleave(
    function(){
        $(".hide_list_scrollbar").show();
    }
);

Right now, the mouse event is performed on all the “a_list” divs. I only want to perform the mouse event on the particular div that actually activated the mouse event, not all of the “a_list” divs. How do I achieve this? Thanks!

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

    Add a context to the selector. See below,

    $(".hide_list_scrollbar", this).hide();
    

    Full Code:

    $(".a_list").mouseenter(function(){
        $(".hide_list_scrollbar", this).hide();
    }).mouseleave(function(){
        $(".hide_list_scrollbar", this).show();
    });
    

    Or you can use .find like below,

    $(".a_list").mouseenter(function(){
        $(this).find(".hide_list_scrollbar").hide();
    }).mouseleave(function(){
        $(this).find(".hide_list_scrollbar").show();
    });
    

    Note: I have chained your call to reduce the query to DOM.

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

Sidebar

Related Questions

I have html that looks something like this: <div> <table> <tr onclick=show();> <td class=cell>Click
i have my html something like this... <div class = content> <div class =
I have some HTML like this: <div id=MyDiv> <div class=Class1> <div class=SClass1></div> </div> <div
My Html is like this: <div style=height: 90px; class=tabtextarea> <div>Description:</div> <textarea style=height: 85px;>TEXT...</textarea> </div>
i have a html text like this: <div id=content> <p>para1</p> <p>para2</p> <p>para3</p> <p class=break>para4</p>
I have HTML like this: <div> <a href=>sometext<img src=images/001.jpg /></a> <a href=>sometext<img src=images/002.jpg /></a>
My html is like this <div id=rsContainer> <table id=rsTable><!-- DATA HERE --></table> </div> and
I have a div directly under the body. My HTML looks like this: <body>
A newbie question,really. Suppose I have a html table like this: <div id=div1> <table
It's a really simple problem. I've got HTML code like this : <div> <img

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.