"Vertical Admin Menu Single Page jQuery"
Bootstrap 3.1.0 Snippet by strikerlg

<link href="//netdna.bootstrapcdn.com/bootstrap/3.1.0/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css"> <script src="//netdna.bootstrapcdn.com/bootstrap/3.1.0/js/bootstrap.min.js"></script> <script src="//code.jquery.com/jquery-1.11.1.min.js"></script> <!------ Include the above in your HEAD tag ----------> <div class="container"> <div class="row"> <div class="col-md-3"> <ul class="nav nav-pills nav-stacked admin-menu"> <li class="active"><a href="#" data-target-id="establishment"><i class="fa fa-home fa-fw"></i> Establishment </a></li> <li><a href="#" data-target-id="administration"><i class="fa fa-list-alt fa-fw"></i> Administration </a></li> <li><a href="#" data-target-id="finance"><i class="fa fa-file-o fa-fw"></i> Finance </a></li> <li><a href="#" data-target-id="supplydemand"><i class="fa fa-bar-chart-o fa-fw"></i> Supply & Demand</a></li> <li><a href="#" data-target-id="vehicle"><i class="fa fa-table fa-fw"></i> Vehicle Management </a></li> <li><a href="#" data-target-id="traffic"><i class="fa fa-tasks fa-fw"></i> Traffic Management </a></li> <li><a href="#" data-target-id="training"><i class="fa fa-calendar fa-fw"></i> Training Management </a></li> <li><a href="#" data-target-id="intelligence"><i class="fa fa-book fa-fw"></i> Intelligence </a></li> <li><a href="#" data-target-id="djms"><i class="fa fa-pencil fa-fw"></i> DJMS </a></li> <li><a href="#" data-target-id="settings"><i class="fa fa-cogs fa-fw"></i> Settings </a></li> </ul> </div> <div class="col-md-9 well admin-content" id="home"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> <div class="col-md-9 well admin-content" id="widgets"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> <div class="col-md-9 well admin-content" id="pages"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> <div class="col-md-9 well admin-content" id="charts"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> <div class="col-md-9 well admin-content" id="table"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> <div class="col-md-9 well admin-content" id="forms"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> <div class="col-md-9 well admin-content" id="calender"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> <div class="col-md-9 well admin-content" id="library"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> <div class="col-md-9 well admin-content" id="applications"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> <div class="col-md-9 well admin-content" id="settings"> <p> Hello! This is a demo snippet.<br> It is for users, which use one-page layouts. </p> </div> </div> </div>
@import url(http://netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.min.css); body{margin-top:20px;} .fa-fw {width: 2em;}
$(document).ready(function() { var navItems = $('.admin-menu li > a'); var navListItems = $('.admin-menu li'); var allWells = $('.admin-content'); var allWellsExceptFirst = $('.admin-content:not(:first)'); allWellsExceptFirst.hide(); navItems.click(function(e) { e.preventDefault(); navListItems.removeClass('active'); $(this).closest('li').addClass('active'); allWells.hide(); var target = $(this).attr('data-target-id'); $('#' + target).show(); }); });

Related: See More


Questions / Comments: