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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T11:00:13+00:00 2026-06-05T11:00:13+00:00

I have my HTML code as; <a href=someTarget.html class=menuLink>Link</a> Now the JS code previously

  • 0

I have my HTML code as;

<a href="someTarget.html" class="menuLink">Link</a>

Now the JS code previously was;

$(".menuLink").mouseover(function(){
    //code for show() submenu
}


$(".menuLink").mouseout(function(){
    //code for hide() submenu
}

I am testing this on iPad and the above code worked fine on the iPad (i.e. on first tap, it fires the hover event and shows the submenu and only on the next tap does it fire the click event or go to the target link)

For some reason (adding delay to the main menu), I had to update the code as follows;

$this.hover(
    function(){ // over
        $this.data("timer", setTimeout(show, 500));
    },
    function(){ // out
        $this.data("timer", setTimeout(hide, 500));
    }
)

So the Issue is as follows;
On the first tap of the link, it immediately takes the user to the target URL (instead of 2 taps earlier for hover/click)

Please help me fix this issue.

  • 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-05T11:00:15+00:00Added an answer on June 5, 2026 at 11:00 am

    jQuery documentation says that $(selector).hover(handlerIn, handlerOut) is just a shortcut for using $(selector).mouseenter(handlerIn).mouseleave(handlerOut).

    That means there is no mouseover()/mouseout() event binded to the object and maybe the mobile browser doesn’t handle it correctly for the other 2 events (that is mouseenter()/mouseleave()).

    Try replacing your code to this:

    $this.mouseover(function(){ // over
            $this.data("timer", setTimeout(show, 500));
        }).mouseout(function(){ // out
            $this.data("timer", setTimeout(hide, 500));
        }
    )
    

    Let me know if that does the trick.

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

Sidebar

Related Questions

I have this html code that I need to parse <a class=sushi-restaurant href=/greatSushi>Best Sushi
I have this html. <a class=link href=www.website.com?id=233253>test1</a> <a class=link href=www.website.com?id=456456>test2</a> How can I hide
I have the following HTML code: <div id=filter-bar> <ul> <li><a href=#image class=current><?php _e('Image','sofa'); ?></a></li>
I have html code like this <tr class=odd> <td><b>Reason for Termination:</b></td> <td>this has bunch
I have HTML code like this: <asp:LinkButton ID=AddButton runat=server OnClick=AddPatientBtn_Click> <span class=Normal>Add</span> </asp:LinkButton> I
I have an html code stored in a string. Now I want to extract
I have this HTML Code: <!doctype html> <html> <head> <meta charset=utf-8> <title>Untitled Document</title> <link
I have a HTML with the following format <article class="cik" id="100"> <a class="ci" href="/abc/1001/STUFF">
I have html which contains such text ....... <a class=product_name href=index.php?productID=29785>Funny</a> ........ <a class=product_name
I have my html code like: <ul id=abc> <li><a href=http://koolfinance.blogspot.com/2011/06/laxmi-bank.html>Laxmi Bank</a></li> <li><a href=http://koolfinance.blogspot.com/2011/06/nepal-development-bank.html>Nepal Development

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.