i am trying to build a simple tabbed interface and i am stalled. All works fine except, when cant seem to find a way to set default tab when loaded.
I would like to see when page loads, i want the tab-1 to be visible. Can it be done using pure css, if not for jquery
Here is the code.
<div class='tabs'>
<ul class='horizontal'>
<li><a href="#tab-1">General</a></li>
<li><a href="#tab-2">Showcase Box</a></li>
</ul>
<div id='tab-1' class="tab"> Tab1 Content here </div> <div id='tab-1' class="tab"> Tab 2 Content here </div>
CSS
.tabs div:not(:target) { display:none; }
.tabs div:target { display:block; }