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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T23:26:03+00:00 2026-06-08T23:26:03+00:00

I have a left navigator that I want to make it hide on a

  • 0

I have a left navigator that I want to make it hide on a user command.

http://jsfiddle.net/Ktqbz/

the “I hide the nav” button should stay visible after it is clicked staying at the same vertical space and reposition itself to the original location when the nav is shown again. How can I accomplish this? I can change the html if needed, I know that when you have display:none, none of its children will be displayed, the flow is also altered so the button wont stay in the same vertical spot. I can change the design too so if you have a better idea I’m all ears. However, this should be as friendly for the user as possible, if I move the button from its vertical spot, people might be confused, thats why I want to keep it there.

  • 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-08T23:26:04+00:00Added an answer on June 8, 2026 at 11:26 pm

    The issue is mainly with your markup. the “I hide the nav button” is contained withing #leftNavigator, so when you hide the #leftNavigator you are also hiding the button that you want to stay visible. There are a number of way to modify your markup to make this work.

    Essentially I just created a wrapper for the navigator and positioned it relatively, and within it I positioned the “I hide the nav button” absolutely. I also added a top margin to the two control panel buttons so that they leave room for the “I hide the nav” button. There are a lot of ways of making this work.

    #leftNavigator{float:left; width:100%; background-color:red;}
    #top{height:150px; background-color:blue;}
    #controlPanel{height:50px; background-color:gray;}
    #tree{background-color:green;}
    #content{overflow:auto; background-color:coffee;}
    #btn{z-index:10;position:absolute;top:150px;}
    ​#navigator_wrapper{position:relative;height:150px;width:20%}
    #controlPanel button {margin-top:25px;}
    

    ​

    <div id="navigator_wrapper">
        <button id="btn">I hide the nav</button>
        <div id="leftNavigator">
            <div id="top">I have an image</div>
            <div id="controlPanel"><button>Other</button><button>controls</button></div>
            <div id="tree">I'm a jstree</div>    
        </div>
    </diV>
    <div id="content">
        I take all the space I want. Except for leftNavigator's space.
    </div>​​​​​​​​​​​​​​​
    

    HERE is a jfiddle http://jsfiddle.net/samisadaka/9c7va/

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

Sidebar

Related Questions

Given this little fiddle: http://jsfiddle.net/5Sw3h/8/ I have a navigation panel to the left, a
My goals: I want to have #nav to be divide into menu-left and menu-right,
I have an ASP.NET MVC Page that has Left Menu navigation that is built
I have a left-positioned navigation that shows/hides content on the right. Currently, when you
I have a JTable which I want to have left-click and right-click JPopupMenu on
I want to have a left justified label with some bold text in it,
I want to have a 2 column layout, and have the left column able
For example, I have a textbox that I need to have a Left property
http://removed.com/jquery/test.html# I have three problems that I need help with. 1 ) When you
I have 3 different Activities that user navigates between in no particular order. My

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.