"Step Wizard (Working)"
Bootstrap 3.0.0 Snippet by neolace

<link href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css"> <script src="//netdna.bootstrapcdn.com/bootstrap/3.0.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"> <section> <ul class="nav nav-pills nav-justified thumbnail"> <li class="active"> <a href="#step1" data-toggle="tab"> <h5>Step 1. First step Description</h5> </a> </li> <li class="disabled"> <a href="#step2" data-toggle="tab"> <h5>Step 2. Second step Description</h5> </a> </li> <li class="disabled"> <a href="#step3" data-toggle="tab"> <h5>Step 3. Third step Description</h5> </a> </li> <li class="disabled"> <a href="#complete" data-toggle="tab"> <h5>Step 4. Step Complete</h5> </a> </li> </ul> <form> <div class="tab-content"> <div class="tab-pane active" id="step1"> <h3 class="well">Step 1. First step Description</h3> <ul class="list-inline pull-right"> <li><button type="button" class="btn btn-primary">Continue</button></li> </ul> </div> <div class="tab-pane" id="step2"> <h3 class="well">Step 2. Second step Description</h3> <ul class="list-inline pull-right"> <li><button type="button" class="btn btn-default">Previous</button></li> <li><button type="button" class="btn btn-primary">Continue</button></li> </ul> </div> <div class="tab-pane" id="step3"> <h3 class="well">Step 3. Third step Description</h3> <ul class="list-inline pull-right"> <li><button type="button" class="btn btn-default">Previous</button></li> <li><button type="button" class="btn btn-primary">Continue</button></li> </ul> </div> <div class="tab-pane" id="complete"> <h3 class="well">Step 4. Step Complete</h3> <p class="pull-right">You have successfully completed all steps.</p> </div> <div class="clearfix"></div> </div> </form> </section> </div> </div>
body{ margin-top:30px; }
$(document).ready(function () { //Wizard $('a[data-toggle="tab"]').on('show.bs.tab', function (e) { var $target = $(e.target); if ($target.parent().hasClass('disabled')) { return false; } }); $(".btn-primary").click(function (e) { var $active = $('.nav-pills li.active'); $active.next().removeClass('disabled'); nextTab($active); }); $(".btn-default").click(function (e) { var $active = $('.nav-pills li.active'); prevTab($active); }); }); function nextTab(elem) { $(elem).next().find('a[data-toggle="tab"]').click(); } function prevTab(elem) { $(elem).prev().find('a[data-toggle="tab"]').click(); }

Related: See More


Questions / Comments: