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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T01:05:27+00:00 2026-06-01T01:05:27+00:00

got an easy question, using jquery, how do i create a menu, with links

  • 0

got an easy question, using jquery, how do i create a menu, with links on the left and with content on the right, for example, if i hover the link with rel=”link1″, the content div on the right with id=”link1″ should be displayed, and when i hover another link with rel=”link2″, the content div with id=”link2″ will be displayed, BUT if i click one of the link, its content div should stay displayed, even if i hover another link 🙂 i hope i was clear in explaining, here is my simple template to practice:

<div id="ref_menu">
    <a href="javascript://" class="ref_link" rel="link1">
        Link 1
    </a>
    <a href="javascript://" class="ref_link" rel="link2">
        Link 2
    </a>
</div>
<div id="ref_content">
    <div class="ref_text" id="link1">
        text1
    </div>
    <div class="ref_text" id="link1">
        text2
    </div>
</div>

css styles:

#ref_menu { width:250px; text-align:right; position:absolute; left:0; }
#ref_menu a { display:block; padding-right:10px; font-family:trebuchet ms; position:relative; font-style:italic; color:#0097c4; font-size:11pt; line-height:30px; letter-spacing:1px; border-bottom:1px solid #0097c4; }
#ref_menu a:hover { color:red; border-bottom:1px solid red; }
#ref_content { position:absolute; left:270px; }
#ref_content div { display:none; position:absolute; top:0; }

and biiiig thanks to those who can spare some time with helping me, i really apreciate it!

  • 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-01T01:05:29+00:00Added an answer on June 1, 2026 at 1:05 am

    Something like that?:

    http://jsfiddle.net/37urb/

    $('a').hover(function(e){
        if($('.stayDisplayed').length == 0){
            var id = $(this).attr('rel');
            $('#'+id).show();
        }
    },function(e){
        if($('.stayDisplayed').length == 0){
            var id = $(this).attr('rel');
            $('#'+id).hide();
        }
    });
    
    $('a').click(function(e){
        var id = $(this).attr('rel');
    
        $('.ref_text').removeClass('stayDisplayed');
        $('.ref_text').hide();
        $('#'+id).addClass('stayDisplayed');
        $('#'+id).show();
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've got a menu in Python. That part was easy. I'm using raw_input() to
I've got a collection (List<Rectangle>) which I need to sort left-right. That part's easy.
I've got such a frustrating question for which I'm convinced there is an easy
Sounds easy, but I've got a bug and I'm not sure what's causing it?
Morning y'all This is probably an easy one but I barely got any sleep
I think this should be easy, but it's evading me. I've got a many-to-many
first post here, and probably an easy one. I've got the code from Processing's
I've got a small dilemma, that should hopefully be easy to resolve. I am
Sorry if this question is too simple or easy. I just started studying Delegates
I'm programming a desktop application in Java using NetBeans . My question is this:

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.