Skip to content

Commit

Permalink
added tab detection from url hash
Browse files Browse the repository at this point in the history
  • Loading branch information
chrismatthieu committed Dec 17, 2011
1 parent bc5805b commit 2f9d5d8
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions api.html
Expand Up @@ -46,6 +46,19 @@

<body>

<script>

$(document).ready(function() {
var hash = window.location.hash.substring(1);
if (hash == "rest") {
$('#restli').addClass("active");
$('#clili').removeClass("active");
$('#cli').removeClass("active");
$('#rest').addClass("active");
}
});
</script>

<div class="topbar">
<div class="fill">
<div class="container">
Expand Down Expand Up @@ -74,8 +87,8 @@ <h1>Nodester Docs</h1>
</p>

<ul class="tabs" data-tabs="tabs">
<li class="active"><a href="#cli">Command Line Interface (CLI)</a></li>
<li><a href="#rest">REST API</a></li>
<li class="active" id="clili"><a href="#cli">Command Line Interface (CLI)</a></li>
<li id="restli"><a href="#rest">REST API</a></li>
</ul>

<div id="my-tab-content" class="tab-content">
Expand Down

0 comments on commit 2f9d5d8

Please sign in to comment.