searchforsolutions

Just another WordPress.com site

Togglable Tabs in Twitter Bootstrap


This is mostly my notes 🙂

Make sure the href element value(e.g. #idvalue ) of nav-tabs & the tab-pane id value are the same(e.g. idvalue).

If the tab element has href value #t1

<a href=”#t1″ data-toggle=”tab”>Section1</a>

then tab-pane id should be t1

<div class=”tab-pane active” id=”t1″>
<p>I’m in Section 1.</p>
</div>

Its not implied or easily visible in the documentation.

I’m a Java/C# developer, started to learn UI recently so its not obvious to me 🙂

Reference :

  1. http://twitter.github.com/bootstrap/javascript.html#tabs
  2. http://twitter.github.com/bootstrap/components.html#navs
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: