Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/409.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 如何使用bootstrap在所有4个选项卡上复制相同的导航菜单?_Javascript_Html_Css_Twitter Bootstrap 3_Navigation - Fatal编程技术网

Javascript 如何使用bootstrap在所有4个选项卡上复制相同的导航菜单?

Javascript 如何使用bootstrap在所有4个选项卡上复制相同的导航菜单?,javascript,html,css,twitter-bootstrap-3,navigation,Javascript,Html,Css,Twitter Bootstrap 3,Navigation,我遇到了一个大问题,试图在我所有的标签页上复制相同的菜单,但运气不好 该菜单位于最后一个选项卡#BuildDesign 到目前为止,我已尝试更改输入[name=“intervaltype”* 和**侧边栏导航a在所有JS、HTML和CSS中以及中。checkAll和。通过在末尾添加2进行检查。[示例:intervaltype2] 我已将代码复制并粘贴到另一个选项卡中,并对id和类进行了所有更改,但无法在其他选项卡上复制菜单 是否有人知道如何复制我的菜单,使其在所有选项卡上都工作? 更新3我更新了

我遇到了一个大问题,试图在我所有的标签页上复制相同的菜单,但运气不好

该菜单位于最后一个选项卡#BuildDesign

到目前为止,我已尝试更改输入[name=“intervaltype”* 和**侧边栏导航a在所有JS、HTML和CSS中以及中。checkAll。通过在末尾添加2进行检查。[示例:intervaltype2]

我已将代码复制并粘贴到另一个选项卡中,并对id和类进行了所有更改,但无法在其他选项卡上复制菜单

是否有人知道如何复制我的菜单,使其在所有选项卡上都工作?

更新3我更新了小提琴,多亏了pwagner指出了结尾的问题 div标签。这个提琴只有一个子菜单,我想在所有的菜单上复制 标签

请注意,当您打开小提琴时,您必须将预览屏幕的宽度至少拉伸到992px才能查看菜单,而且菜单也会一直放置在扩音器右侧的最后一个图标中。[单击它]

奖励:由于某些原因,顶部的.servicelist图标的颜色应为橙色,但此代码会覆盖servicelist的颜色:

 .sidebar-nav a.active {
color:#39f; background-color:#eee; 
Javascript:

//Selection Active       
$('.sidebar-nav a').click(function() {
    $('a').removeClass();

    $(this).addClass('active');
}); 

//Custom Toggle  
$('input[name="intervaltype"]').click(function () {

    $('#Custom').toggleClass('active');
    $('#Types').toggleClass('active');
});

//Check and Uncheck
$(".checkAll").click(function () {
    $(".check").prop('checked', $(this).prop('checked'));
});

//Selection Active       
$('.servicelist a').click(function() {
    $('a').removeClass();

    $(this).addClass('active');
}); 
    <div id="sidebar-wrapper2">

         <!-- Sidebar -->
   <div class="topfilter">

     <div class="tabber">

   <!-- Nav tabs -->
  <ul class="servicelist" role="tablist">

    <li class="col-md-3 col-xs-3 serviceop active" role="presentation">
    <a href="#construction" aria-controls="construction" role="tab" data-toggle="tab">
    <i class="fa-2x fa fa-home"></i>
    </a>
    </li>

    <li class="serviceop col-md-3 col-xs-3"  role="presentation">
    <a href="#precon" aria-controls="precon" role="tab" data-toggle="tab">
    <i class="fa-2x fa fa-info-circle"></i> 
    </a>
    </li>

    <li class="col-md-3 col-xs-3 serviceop" role="presentation">
    <a href="#generalcon" aria-controls="generalcon" role="tab" data-toggle="tab">
    <i class="fa-2x fa fa-briefcase"></i> 
    </a>
    </li>

    <li class="col-md-3 col-xs-3 serviceop" role="presentation">
    <a href="#builddesign" aria-controls="builddesign" role="tab" data-toggle="tab">
    <i class="fa-2x fa fa-bullhorn"></i>
    </a>
    </li>

  </ul>

</div> <!-- End Tabber-->
</div><!-- End Topfilter-->

</div> <!-- End sidebar-wrapper 2--> 


   <!-- Tab panes -->
 <div class="tab-content">

    <div role="tabpanel" class="tab-pane fade in active" id="construction"> 

               <br />
               <br />
                                    <h2>Default</h2>

      </div>  <!-- Close Tab Panel -->

    <div role="tabpanel" class="tab-pane fade" id="precon">
               <br />   
               <br />     
                            <h2>2nd Tab</h2>

      </div>  <!-- Close Tab Panel -->



      <div role="tabpanel" class="tab-pane fade" id="generalcon">


                       <br />   
               <br />     
                            <h2>3rd Tab</h2>

      </div> <!-- Close Tab Panel -->


 <div role="tabpanel" class="tab-pane fade" id="builddesign">
 <div id="sidebar-wrapper3">

             <li class="toppy" role="tab" style="list-style:none;">
            <label data-target="#Custom"> <span class="customtext">Choose</span>    
                <input name="intervaltype" class="check checkAll chix" type="checkbox" />
                       </label>
        </li>


</div>                       
<div class="tab-content" id="sidebar-wrapper">


   <div role="tabpanel" class="tab-pane" id="Custom">

    <ul class="sidebar-nav">

     <form role="form">
  <div class="form-group">

      <div class="checkbox">
    <label>
      <input type="checkbox" class="check checkAll"> Settings
    </label>
  </div>

    <div class="checkbox">
    <label>
      <input type="checkbox" class="check"> Log out
    </label>
  </div>


    <div class="checkbox">
    <label>
      <input type="checkbox" class="check">Profile
    </label>
  </div>

    <div class="checkbox">
    <label>
      <input type="checkbox" class="check"> Account
    </label>
  </div>

  </div><!-- End Form-group -->
  </form>

   </ul> <!-- End Sidebar Nav-->

        </div> <!-- End Tab Panel-->


  <div role="tabpanel" class="tab-pane active" id="Types">

    <ul class="sidebar-nav">

          <div class="panel panel-default">
                    <div class="panel-heading">
                        <h4 class="panel-title">
                            <a class="active highlight" data-toggle="collapse" data-parent="#accordion" href="#collapseZero"><span class="iconpad glyphicon glyphicon glyphicon-asterisk">
                            </span>Call Me</a>
                        </h4>
                    </div><!-- End Panel-Heading -->



 <div class="panel-group" id="accordion">
                <div class="panel panel-default">
                    <div class="panel-heading">
                        <h4 class="panel-title">
                            <a class="highlight" data-toggle="collapse" data-parent="#accordion" href="#collapseOne"><span class="iconpad glyphicon glyphicon-user">
                            </span>Log</a>
                        </h4>
                    </div> <!-- End Panel-Heading -->

       <div id="collapseOne" class="panel-collapse collapse in">
      <li>
      <a class="highlight" href="#/content">
       Loglines
       </a>
      </li>
       </div>  <!-- End CollapseOne -->


    <div class="bottomfilter">
   <a href="#" class="filtertitle">Terms</a>    

   </div>  <!-- End Bottom Filter -->


  </div> <!-- End Panel Default in Accordion -->

   </div><!-- End Accordion -->


    </div> <!-- End Panel Default -->


   </ul> <!-- End Sidebar Nav-->


   </div> <!-- End Types 1 -->


    </div> <!-- End SideBar Wrapper 1 -->

</div> <!-- End Tab Panel -->

</div> <!-- End Tabs Content -->
a {outline:none !important;}

html,
body,
.wrap {
  height: 100%;
}

.wrap {
  box-sizing: border-box;
}

form {
  height: 100%
}

.wrap {
  min-height: 100%;
  height: auto !important;
  height: 100%;
  margin-bottom: -60px;
  /* for sticky footer to not go below page */
  /* for sticky header to not overlap content */
}

.push,
.footer {
  height: 60px;
}



.footer {
  background-color: #ebebeb;
  height: 60px;
  width: 100%;
  position: fixed;
  bottom: 0;   
}

.content {
  position: absolute;
  width: 100%;
  top: 120px;
  background-color: yellow;
  z-index: 0;
}


#sidebar-wrapper {
  z-index: 1000;
  position: fixed;
  left: 142px;
height:95%;
  width: 0; bottom:0; top:65px;
  height:auto; border-top:1px solid #fff;
  margin-left: -142px;
  overflow-y: auto; overflow-x:hidden;
  background: #eee;
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

#sidebar-wrapper2 {
  z-index: 1000;
  position: fixed;
  left: 142px;
  top:0; 
  margin-bottom: 0px;
  width:100%;
  min-height:55px;  height:auto; 
  margin-left: -142px;
  background: #eee; 
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}


#sidebar-wrapper3 {
  z-index: 1000;
  position: fixed;
  left: 142px;
  top:35px; 
  margin-bottom: 0px;
  width:auto;
  min-height:55px;  height:auto; 
  margin-left: -142px;
  background: #eee; 
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

.filtertitle { position:relative; display:inline-block; color:#000; width:auto; }

.topfilter { max-width:100%; min-width:100%; position:relative; display:inline-block; min-height:65px;  }

.tabber {bottom:0px !important; height:auto; left:0;  position:relative; display:inline-block; border-bottom: solid #fff 1px; }

.customtext {color:#666;}

.toppy {bottom:0px !important; text-indent:9px; }

.bottomfilter {border-top: solid #666 1px; width:100%; height:auto;  position:relative; display:block; text-align:left; background-color:#eee;  }

.checkbox {margin-left:25px !important;}

.dropdown { margin-top:15%; display:inline-block; }

.dropdown a {margin-left:20px; min-width:100% !important;  }

.caret {text-align:right !important; position:relative;}

#wrapper.toggled #sidebar-wrapper {
  width: 200px;  
}

#wrapper.toggled #sidebar-wrapper2 {
  width: 200px;  
}


#page-content-wrapper {
  width: 100%;
  position: absolute;
  padding: 15px;
}

   #wrapper.toggled #page-content-wrapper {
  position: absolute;
  margin-right: -200px;
}


/* Sidebar Styles */

.sidebar-nav {
  position: absolute;
  top: 0px;
  width:inherit; min-width:100%;  
  margin: 0;
  padding: 0;  
  list-style: none;
}

.sidebar-nav li {
  text-indent: 20px;
  line-height: 40px; 
}

.sidebar-nav li a {
  display: block; 
  text-decoration: none;
  color: #999999;
}

.sidebar-nav li a:hover {
  text-decoration: none;
  color: #666; 
  background:#bdc3c7;
}

.sidebar-nav li a:active,
.sidebar-nav li a:focus {
  text-decoration: none;
}

.sidebar-nav > .sidebar-brand {
  height: 65px;
  font-size: 18px;
  line-height: 60px;
}

.sidebar-nav > .sidebar-brand a {
  color: #999999;
}

.sidebar-nav > .sidebar-brand a:hover {
  color: #fff;
  background: none;
}

@media screen and (min-width:768px) {
  #wrapper {
    padding-left: 300px;
  }
  #wrapper.toggled {
    padding-left: 0;
  }


  #wrapper.toggled #sidebar-wrapper {
    width: 0;
  }
  #page-content-wrapper {
    padding: 20px;
    position: relative;
  }
  #wrapper.toggled #page-content-wrapper {
    position: relative;
    margin-right: 0;
  }
}


@media screen and (max-width:1526px) {

  .content,
  .footer {
    width: 82%;
    right: 0; 
  }
  .header {width:82%;}

    #sidebar-wrapper {
    width: 18%; 
  }
    #sidebar-wrapper2 {
    width: 18%; 
  }

}


@media screen and (max-width:1059px) {

  .content,
  .footer {
    width: 80%;
    right: 0; 
  }

  .header {width:80%;}

    #sidebar-wrapper {
    width: 20%; 
  }

     #sidebar-wrapper2 {
    width: 20%; 
  }
}   

     @media screen and (min-width:1527px) {

  .content,
  .footer {
    width: 85%;
    right: 0; 
  }
  .header {width:85%;}
    #sidebar-wrapper {
    width: 15%; 
  }

     #sidebar-wrapper2 {
    width: 15%; 
  }


}

        @media screen and (max-width:991px) {
          .content,
  .footer {
    width: 100%;
    right: 0; 
  }

  .filtertitle {display:none;}

    #sidebar-wrapper {
    width:0;   
  }

    #sidebar-wrapper2 {
    width:0;   
  }
  .topfilter {width:0; display:none;}

.dropdown a {display:none;}



}

.iconpad { margin-right:10px; }
.panel-body { padding:0px; }
.panel-body table tr td { padding-left: 15px }
.panel-body .table {margin-bottom: 0px; }

.panel-title a:hover {color:#333; text-decoration:none;  background:none !important;}

.panel-title a:focus {color:#39f; text-decoration:none; background:none !important;}

.panel-title a {text-decoration:none; background:none !important;}

    .sidebar-nav a:hover {
            color: #666; 
        }

.sidebar-nav a.active {
color:#39f; background-color:#eee;   





.servicelist {  list-style:none; padding:0; }

.servicelist a{ background:none !important; text-decoration:none; color:#333;  list-style:none; }

.servicelist a :hover {  color:#bdc3c7;  }

.servicelist > li.active > a .fa-2x {
color:#f90;
   cursor: pointer;
}
HTML:

//Selection Active       
$('.sidebar-nav a').click(function() {
    $('a').removeClass();

    $(this).addClass('active');
}); 

//Custom Toggle  
$('input[name="intervaltype"]').click(function () {

    $('#Custom').toggleClass('active');
    $('#Types').toggleClass('active');
});

//Check and Uncheck
$(".checkAll").click(function () {
    $(".check").prop('checked', $(this).prop('checked'));
});

//Selection Active       
$('.servicelist a').click(function() {
    $('a').removeClass();

    $(this).addClass('active');
}); 
    <div id="sidebar-wrapper2">

         <!-- Sidebar -->
   <div class="topfilter">

     <div class="tabber">

   <!-- Nav tabs -->
  <ul class="servicelist" role="tablist">

    <li class="col-md-3 col-xs-3 serviceop active" role="presentation">
    <a href="#construction" aria-controls="construction" role="tab" data-toggle="tab">
    <i class="fa-2x fa fa-home"></i>
    </a>
    </li>

    <li class="serviceop col-md-3 col-xs-3"  role="presentation">
    <a href="#precon" aria-controls="precon" role="tab" data-toggle="tab">
    <i class="fa-2x fa fa-info-circle"></i> 
    </a>
    </li>

    <li class="col-md-3 col-xs-3 serviceop" role="presentation">
    <a href="#generalcon" aria-controls="generalcon" role="tab" data-toggle="tab">
    <i class="fa-2x fa fa-briefcase"></i> 
    </a>
    </li>

    <li class="col-md-3 col-xs-3 serviceop" role="presentation">
    <a href="#builddesign" aria-controls="builddesign" role="tab" data-toggle="tab">
    <i class="fa-2x fa fa-bullhorn"></i>
    </a>
    </li>

  </ul>

</div> <!-- End Tabber-->
</div><!-- End Topfilter-->

</div> <!-- End sidebar-wrapper 2--> 


   <!-- Tab panes -->
 <div class="tab-content">

    <div role="tabpanel" class="tab-pane fade in active" id="construction"> 

               <br />
               <br />
                                    <h2>Default</h2>

      </div>  <!-- Close Tab Panel -->

    <div role="tabpanel" class="tab-pane fade" id="precon">
               <br />   
               <br />     
                            <h2>2nd Tab</h2>

      </div>  <!-- Close Tab Panel -->



      <div role="tabpanel" class="tab-pane fade" id="generalcon">


                       <br />   
               <br />     
                            <h2>3rd Tab</h2>

      </div> <!-- Close Tab Panel -->


 <div role="tabpanel" class="tab-pane fade" id="builddesign">
 <div id="sidebar-wrapper3">

             <li class="toppy" role="tab" style="list-style:none;">
            <label data-target="#Custom"> <span class="customtext">Choose</span>    
                <input name="intervaltype" class="check checkAll chix" type="checkbox" />
                       </label>
        </li>


</div>                       
<div class="tab-content" id="sidebar-wrapper">


   <div role="tabpanel" class="tab-pane" id="Custom">

    <ul class="sidebar-nav">

     <form role="form">
  <div class="form-group">

      <div class="checkbox">
    <label>
      <input type="checkbox" class="check checkAll"> Settings
    </label>
  </div>

    <div class="checkbox">
    <label>
      <input type="checkbox" class="check"> Log out
    </label>
  </div>


    <div class="checkbox">
    <label>
      <input type="checkbox" class="check">Profile
    </label>
  </div>

    <div class="checkbox">
    <label>
      <input type="checkbox" class="check"> Account
    </label>
  </div>

  </div><!-- End Form-group -->
  </form>

   </ul> <!-- End Sidebar Nav-->

        </div> <!-- End Tab Panel-->


  <div role="tabpanel" class="tab-pane active" id="Types">

    <ul class="sidebar-nav">

          <div class="panel panel-default">
                    <div class="panel-heading">
                        <h4 class="panel-title">
                            <a class="active highlight" data-toggle="collapse" data-parent="#accordion" href="#collapseZero"><span class="iconpad glyphicon glyphicon glyphicon-asterisk">
                            </span>Call Me</a>
                        </h4>
                    </div><!-- End Panel-Heading -->



 <div class="panel-group" id="accordion">
                <div class="panel panel-default">
                    <div class="panel-heading">
                        <h4 class="panel-title">
                            <a class="highlight" data-toggle="collapse" data-parent="#accordion" href="#collapseOne"><span class="iconpad glyphicon glyphicon-user">
                            </span>Log</a>
                        </h4>
                    </div> <!-- End Panel-Heading -->

       <div id="collapseOne" class="panel-collapse collapse in">
      <li>
      <a class="highlight" href="#/content">
       Loglines
       </a>
      </li>
       </div>  <!-- End CollapseOne -->


    <div class="bottomfilter">
   <a href="#" class="filtertitle">Terms</a>    

   </div>  <!-- End Bottom Filter -->


  </div> <!-- End Panel Default in Accordion -->

   </div><!-- End Accordion -->


    </div> <!-- End Panel Default -->


   </ul> <!-- End Sidebar Nav-->


   </div> <!-- End Types 1 -->


    </div> <!-- End SideBar Wrapper 1 -->

</div> <!-- End Tab Panel -->

</div> <!-- End Tabs Content -->
a {outline:none !important;}

html,
body,
.wrap {
  height: 100%;
}

.wrap {
  box-sizing: border-box;
}

form {
  height: 100%
}

.wrap {
  min-height: 100%;
  height: auto !important;
  height: 100%;
  margin-bottom: -60px;
  /* for sticky footer to not go below page */
  /* for sticky header to not overlap content */
}

.push,
.footer {
  height: 60px;
}



.footer {
  background-color: #ebebeb;
  height: 60px;
  width: 100%;
  position: fixed;
  bottom: 0;   
}

.content {
  position: absolute;
  width: 100%;
  top: 120px;
  background-color: yellow;
  z-index: 0;
}


#sidebar-wrapper {
  z-index: 1000;
  position: fixed;
  left: 142px;
height:95%;
  width: 0; bottom:0; top:65px;
  height:auto; border-top:1px solid #fff;
  margin-left: -142px;
  overflow-y: auto; overflow-x:hidden;
  background: #eee;
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

#sidebar-wrapper2 {
  z-index: 1000;
  position: fixed;
  left: 142px;
  top:0; 
  margin-bottom: 0px;
  width:100%;
  min-height:55px;  height:auto; 
  margin-left: -142px;
  background: #eee; 
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}


#sidebar-wrapper3 {
  z-index: 1000;
  position: fixed;
  left: 142px;
  top:35px; 
  margin-bottom: 0px;
  width:auto;
  min-height:55px;  height:auto; 
  margin-left: -142px;
  background: #eee; 
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

.filtertitle { position:relative; display:inline-block; color:#000; width:auto; }

.topfilter { max-width:100%; min-width:100%; position:relative; display:inline-block; min-height:65px;  }

.tabber {bottom:0px !important; height:auto; left:0;  position:relative; display:inline-block; border-bottom: solid #fff 1px; }

.customtext {color:#666;}

.toppy {bottom:0px !important; text-indent:9px; }

.bottomfilter {border-top: solid #666 1px; width:100%; height:auto;  position:relative; display:block; text-align:left; background-color:#eee;  }

.checkbox {margin-left:25px !important;}

.dropdown { margin-top:15%; display:inline-block; }

.dropdown a {margin-left:20px; min-width:100% !important;  }

.caret {text-align:right !important; position:relative;}

#wrapper.toggled #sidebar-wrapper {
  width: 200px;  
}

#wrapper.toggled #sidebar-wrapper2 {
  width: 200px;  
}


#page-content-wrapper {
  width: 100%;
  position: absolute;
  padding: 15px;
}

   #wrapper.toggled #page-content-wrapper {
  position: absolute;
  margin-right: -200px;
}


/* Sidebar Styles */

.sidebar-nav {
  position: absolute;
  top: 0px;
  width:inherit; min-width:100%;  
  margin: 0;
  padding: 0;  
  list-style: none;
}

.sidebar-nav li {
  text-indent: 20px;
  line-height: 40px; 
}

.sidebar-nav li a {
  display: block; 
  text-decoration: none;
  color: #999999;
}

.sidebar-nav li a:hover {
  text-decoration: none;
  color: #666; 
  background:#bdc3c7;
}

.sidebar-nav li a:active,
.sidebar-nav li a:focus {
  text-decoration: none;
}

.sidebar-nav > .sidebar-brand {
  height: 65px;
  font-size: 18px;
  line-height: 60px;
}

.sidebar-nav > .sidebar-brand a {
  color: #999999;
}

.sidebar-nav > .sidebar-brand a:hover {
  color: #fff;
  background: none;
}

@media screen and (min-width:768px) {
  #wrapper {
    padding-left: 300px;
  }
  #wrapper.toggled {
    padding-left: 0;
  }


  #wrapper.toggled #sidebar-wrapper {
    width: 0;
  }
  #page-content-wrapper {
    padding: 20px;
    position: relative;
  }
  #wrapper.toggled #page-content-wrapper {
    position: relative;
    margin-right: 0;
  }
}


@media screen and (max-width:1526px) {

  .content,
  .footer {
    width: 82%;
    right: 0; 
  }
  .header {width:82%;}

    #sidebar-wrapper {
    width: 18%; 
  }
    #sidebar-wrapper2 {
    width: 18%; 
  }

}


@media screen and (max-width:1059px) {

  .content,
  .footer {
    width: 80%;
    right: 0; 
  }

  .header {width:80%;}

    #sidebar-wrapper {
    width: 20%; 
  }

     #sidebar-wrapper2 {
    width: 20%; 
  }
}   

     @media screen and (min-width:1527px) {

  .content,
  .footer {
    width: 85%;
    right: 0; 
  }
  .header {width:85%;}
    #sidebar-wrapper {
    width: 15%; 
  }

     #sidebar-wrapper2 {
    width: 15%; 
  }


}

        @media screen and (max-width:991px) {
          .content,
  .footer {
    width: 100%;
    right: 0; 
  }

  .filtertitle {display:none;}

    #sidebar-wrapper {
    width:0;   
  }

    #sidebar-wrapper2 {
    width:0;   
  }
  .topfilter {width:0; display:none;}

.dropdown a {display:none;}



}

.iconpad { margin-right:10px; }
.panel-body { padding:0px; }
.panel-body table tr td { padding-left: 15px }
.panel-body .table {margin-bottom: 0px; }

.panel-title a:hover {color:#333; text-decoration:none;  background:none !important;}

.panel-title a:focus {color:#39f; text-decoration:none; background:none !important;}

.panel-title a {text-decoration:none; background:none !important;}

    .sidebar-nav a:hover {
            color: #666; 
        }

.sidebar-nav a.active {
color:#39f; background-color:#eee;   





.servicelist {  list-style:none; padding:0; }

.servicelist a{ background:none !important; text-decoration:none; color:#333;  list-style:none; }

.servicelist a :hover {  color:#bdc3c7;  }

.servicelist > li.active > a .fa-2x {
color:#f90;
   cursor: pointer;
}

我终于解决了这个问题,我将在这里为任何对我的解决方案感兴趣的人发布代码

这就是解决办法:

我是如何解决的: 一旦我修复了所有的div并确保它们都有结束标签,我就做了以下工作:

1。我从选项卡面板复制并粘贴了菜单代码,并将该代码块粘贴到所有选项卡面板上

2.然后,我更改了html中以下复制项的名称,然后在css中复制了原始代码,并使用新名称复制了javascript:

.sidebar-nav, .sidebar-nav2, .sidebar-nav3, and .sidebar-nav4 

 #Custom, #Custom2, #Custom3, #Custom4 

#Types, #Types2, #Types3, #Types4 

 intervaltype, intervaltype2, intervaltype3, intervaltype4

.checkBelow, .checkBelow2, .checkBelow3, .checkBelow4

.checkother, .checkother2, .checkother3, .checkother4

.check, check2, .check3, .check4

.checkAll,.checkAll2,.checkAll3, .checkAll4

#accordion, #accordion2, #accordion3, #accordion4

collapseZero, collapseOne, bcollapseZero, bcollapseOne, ccollapseZero, ccollapseOne, dcollapseZero, dcollapseOne  
奖励:对于我遇到的颜色问题,我只是删除了这段代码: .侧边栏导航a:悬停{ 颜色:#666; }

.sidebar-nav a.active {
color:#39f; background-color:#eee;   

我终于解决了这个问题,我将在这里为任何对我的解决方案感兴趣的人发布代码

这就是解决办法:

我是如何解决的: 一旦我修复了所有的div并确保它们都有结束标签,我就做了以下工作:

1。我从选项卡面板复制并粘贴了菜单代码,并将该代码块粘贴到所有选项卡面板上

2.然后,我更改了html中以下复制项的名称,然后在css中复制了原始代码,并使用新名称复制了javascript:

.sidebar-nav, .sidebar-nav2, .sidebar-nav3, and .sidebar-nav4 

 #Custom, #Custom2, #Custom3, #Custom4 

#Types, #Types2, #Types3, #Types4 

 intervaltype, intervaltype2, intervaltype3, intervaltype4

.checkBelow, .checkBelow2, .checkBelow3, .checkBelow4

.checkother, .checkother2, .checkother3, .checkother4

.check, check2, .check3, .check4

.checkAll,.checkAll2,.checkAll3, .checkAll4

#accordion, #accordion2, #accordion3, #accordion4

collapseZero, collapseOne, bcollapseZero, bcollapseOne, ccollapseZero, ccollapseOne, dcollapseZero, dcollapseOne  
奖励:对于我遇到的颜色问题,我只是删除了这段代码: .侧边栏导航a:悬停{ 颜色:#666; }

.sidebar-nav a.active {
color:#39f; background-color:#eee;   

抱歉,我不明白你的确切意思。但是JSFIDLE链接只是呈现了一个“默认”标题——也许这会阻止其他人帮助你。抱歉,你只需点击最右边的图标,并确保由于这个css选择器代码@media screen和(最大宽度:991px)我会将详细信息添加到小提琴谢谢,现在我看到了扩音器及其子菜单。我仍然不明白“复制我的菜单以便它在所有选项卡上工作”的意思。当我单击主页图标时,我看到“默认”。您可以复制并粘贴扩音器下的现有子菜单,然后进一步调整。我尝试复制并粘贴代码,但没有成功,我在上面提到了我在将代码复制并粘贴到其他选项卡时尝试的策略。我更改了所有id和目标的名称,但没有成功。您可以尝试并让我知道它是否有效吗是给你的吗?很抱歉,我无法让它工作。如果你重新格式化代码并检查所有内容是否正确包装,可能会在HTML标记的嵌套中发现问题。例如,有时类为“tab content”的div也有类似“sidebar wrapper”的id,这看起来不太正确,有时不是。对不起,我不明白你的确切意思。但是jsfiddle链接只是呈现了一个“Default”标题-这可能会妨碍其他人帮助您。抱歉,您只需单击最右侧的图标,并确保由于此css选择器代码@media screen和(最大宽度:991px),小提琴预览窗口延伸至992px我会把细节添加到小提琴上谢谢,现在我看到了扩音器及其子菜单。我仍然不明白“复制我的菜单以便它在所有选项卡上工作”的意思。当我单击主页图标时,我看到了“默认”。您可以复制并粘贴扩音器下的现有子菜单,然后进一步调整。我尝试复制并粘贴代码,但没有成功,我在上面提到了我在将代码复制并粘贴到其他选项卡时尝试的策略。我更改了所有id和目标的名称,但没有成功。您可以尝试并让我知道它是否有效吗这是给你的?很抱歉,我无法让它工作。如果你重新格式化代码并检查所有内容是否正确包装,可能你会在HTML标记的嵌套中发现问题。例如,有时一个类为“tab content”的div也有一个类似于“边栏包装器”的id,而有时则没有。