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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T20:48:17+00:00 2026-05-20T20:48:17+00:00

I have a show/hide script in place that I want to extend but curious

  • 0

I have a show/hide script in place that I want to extend but curious as to the easiest way to extend it’s functionality.

At present you can click on a main link and it opens up the corresponding div with further links inside that.

http://jsfiddle.net/nX8mr/

I would like to extend it so that each list item has a div/image (I’ve included an image just for the example) that is hidden until clicked but will always appear in the same position on the right. So the functionality is more like…

1) Click a Main Link
2) Open Up respective Div with further links
3) Show First List Items div/image
4) On click of any other link in Div then show that List Items div/image instead and hide previous

Not sure if to try and include another show/hide for the individual list div/image or not?

Any help/suggestions would be appreciated.

Update

It seems replicating the show/hide seems easiest. This did it in the end…

$('[class^=showHide], [class^=showHide] img').hide();

$('[class^=link]').click(function() {
    var x =  $(this).attr("className");
    var $item = $('.showHide-' + x);
    if (!$item.is(":visible")) $('[class^=showHide]').hide();
    $('.showHide-' + x).slideToggle();
    return false;
    });

$('[class^=showHide] li').click(function() {
    var x =  $(this);
    if (!$(x).find('img').is(":visible")) $('[class^=showHide] li img').hide();
    $(x).find('img').slideToggle();
    return false;
    });
  • 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-20T20:48:17+00:00Added an answer on May 20, 2026 at 8:48 pm

    Not sure if to try and include another show/hide for the individual list div/image or not?

    That’s what I would do. You can just replicate what you’re doing to show/hide the links, doing to to the images as well.

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

Sidebar

Related Questions

I have a customized show/hide toggle script that I'm using along with CSS3 transitions
I have a simple show/hide jquery script that works fine on its own, The
I have Divs show and hide (with an animation) using the following script (I
I have some js (show/hide pretty standard I guess): <script> function showTransactions(transactions){ $('.steps').hide() $('#'
I have this jquery script which suppose to hide/show div element base on the
I have created some functional categories that I use to show/hide markup elements. However,
I am hoping that someone can help me. I have found this jquery script
I have a button on click of which i want to either show/hide a
I have realized show/hide function in css. But it's not what i need. i
I have the following code where I want to show / hide different text

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.