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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T10:59:11+00:00 2026-05-26T10:59:11+00:00

Javascript $(#col).hover(function (){ $(#cool).toggle(); }); <div> <ul id=col> <li>Sports</li> <ul id=cool style=padding-left:0px;display:none> <li>Tennis</li> <li>Basketball</li>

  • 0
Javascript

$("#col").hover(function (){
   $("#cool").toggle();
});

<div>
<ul id="col">
<li>Sports</li>
<ul id="cool" style="padding-left:0px;display:none">
<li>Tennis</li>
<li>Basketball</li>
</ul>
</ul>
</div>
<div style="position:fixed;z-index:-1">
<strong>Wanna be?</strong>
</div>

I was trying to create a drowdown menu list.Its working fine as i expected, except one case.When I hover my mouse over the sports word, Tennis and basketball seems to appear but the word wanna be? is pushed down but I want the position to be fixed. I used position-fixed and also z-index as -1 , I dont know if they are used these way but i found them on google

But still the word ‘wanna be?’ is going down on hover effect but I want it to be fixed and it should be behind the tennis and basketball menu when hover takes effect.

Please help me with these. any help is greatly appreciated. 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-05-26T10:59:12+00:00Added an answer on May 26, 2026 at 10:59 am

    Just add the position: absolute; to “cool” UL

    <div>
    <ul id="col">
    <li>Sports</li>
    <ul id="cool" style="position: absolute;padding-left:0px;display:none">
    <li>Tennis</li>
    <li>Basketball</li>
    </ul>
    </ul>
    <div style=" z-index:-1">
    <strong>Wanna be?</strong>
    </div>
    </div>
    

    check this demo

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

Sidebar

Related Questions

Hi I have this HTML code <th scope=col class= style=width: 13px;> <div class=some-handle></div> <a
This is my html: <div class=head style=height: 100px;></div> <div class=wrapper> <div class=col>col1</div> <div class=col>col2</div>
JavaScript does funky automatic conversions with objects: var o = {toString: function() {return 40;
I want to populate a predefined html table using JavaScript: <table> <tr> <th scope=col>ID</th>
Awhile back, I found the following javascript function that allows you to dynamically add
I have a javascript code, containing an array with trailing comma items:[{ id: 'col-1',
<script type=text/javascript> var temp=document.getElementById(col).value; var temp2=temp.split(%); for(i=0;i<col.length;i++) { val = temp2[0]+temp2[1]+temp2[2]; /* ... */
JavaScript post request like a form submit shows you how to submit a form
JavaScript allows functions to be treated as objects--if you first define a variable as
Javascript: The Good Parts is a great book. Often I find myself reading passages

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.