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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T14:56:38+00:00 2026-06-14T14:56:38+00:00

HTML Code: <div id=slick-slidetoggle>wxyz</div> <div id=slickbox >abcd</div>​ JavaScript: var hoverVariable=false; var hoverVariable2=false; $(‘#slickbox’).hide(); $(‘#slick-slidetoggle’).mouseover(function()

  • 0

HTML Code:

<div id="slick-slidetoggle">wxyz</div>           
<div id="slickbox" >abcd</div>​

JavaScript:

var hoverVariable=false;
var hoverVariable2=false;

$('#slickbox').hide();
$('#slick-slidetoggle').mouseover(function() {
    hoverVariable2=true;
    $('#slickbox').slideToggle(600);
    return false;
})
$('#slick-slidetoggle').mouseleave(function() {
    hoverVariable2=false;
    setTimeout(function (){
    if(!hoverVariable && !hoverVariable2){
    $('#slickbox').slideToggle(600);
    return false;}
    }, 1000);
})
$('#slickbox').mouseleave(function() {                    
    hoverVariable=false;
    setTimeout(function (){
    if(!hoverVariable && !hoverVariable2){                    
    $('#slickbox').slideToggle(600);
    return false;}
    return false;
    }, 1000); 
})
$('#slickbox').mouseover(function() {
        hoverVariable2=false;

    hoverVariable=true;

})​

CSS Code:

#slickbox {
    background: black;
    width:100px;
    height: 135px;
    display: none; 
    cursor:pointer;
    color:white;
}
#slick-slidetoggle{
 background: yellow;
    width:100px;
    height: 135px;
    cursor:pointer;
    color:black;

}
​

Now the desired behaviour is that when mouse is slide over yellow div(“wxyz”) black div(“abcd”) should slide down and if mouse is moved out of yellow without moving on to black div, the black div should hide after two seconds.

This is happening. If mouse is moved over black div immediately after moving out of yellow div the black div should not hide as long as the mouse is on the black div. This is also happening.

Next steps are bit difficult to explain but I’ll try, when mouse is moved over yellow div and black div comes out then mouse is moved over black div and within two seconds if it moved out of it(black div) then the whole animation goes haywire. Its behaviour is reversed. But if the mouse is kept on black div for more than two seconds and then it is moved out then the whole script runs fine.

This is the link to explain better. http://jsfiddle.net/HAQyK/381/

  • 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-14T14:56:40+00:00Added an answer on June 14, 2026 at 2:56 pm

    Try replacing slideToggle() with the appropriate slideUp() and slideDown() calls. http://jsfiddle.net/tppiotrowski/HAQyK/386/

    var hoverVariable = false;
    var hoverVariable2 = false;
    
    $('#slickbox').hide();
    $('#slick-slidetoggle').mouseover(function() {
        hoverVariable2 = true;
        $('#slickbox').slideDown(600);
        return false;
    })
    $('#slick-slidetoggle').mouseleave(function() {
        hoverVariable2 = false;
        setTimeout(function() {
            if (!hoverVariable && !hoverVariable2) {
                $('#slickbox').slideUp(600);
                return false;
            }
        }, 1000);
    })
    $('#slickbox').mouseleave(function() {
        hoverVariable = false;
        setTimeout(function() {
            if (!hoverVariable && !hoverVariable2) {
                $('#slickbox').slideUp(600);
                return false;
            }
            return false;
        }, 1000);
    })
    $('#slickbox').mouseover(function() {
        hoverVariable2 = false;
        hoverVariable = true;
    })​
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

HTML code: <div class=goleft> AD 300x250 size </div> <div class=itemImageBlock goleft> <span class=itemImage> <img
HTML code: <div class=clearfix style=color: #555 style=display:block; > <input type=text id=id_site placeholder=nom-du-site style=width: 245px;
The html code is pasted into this url http://jsfiddle.net/nzYjV/ The div (id=input) contains the
In a DIV I place some text/html code which get loaded from a database.
my html code <div id=content_main></div> css #content_main { width:1024px; height:150px; background:url('../images/Orange.jpg'); background-repeat:no-repeat; background-size:1024px 150px;
My html code is: <div title=test class=xyz>Tesing</div> I want it to look like: <a
My HTML code goes like this: <div id=single><br><br> 1) effew<br> <input name=answer0 id=answer0 value=1
Consider the following html code: <div id='x'><div id='y'>Y content</div>X content</div> I'd like to extract
I have this HTML code: <div class='com_box'> <div class='com_box_c'> <div class='com_box_info'> <a id='quote'>quote</a> </div>
I have this HTML code: <div id=main> <div id=dv_7>...</div> <div id=dv_1>...</div> <div id=dv_8>...</div> <div

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.