Time for action – creating simple tabs
Perform the following steps to turn a list of links into tabs:
We'll get started with our basic HTML file and associated folders, like we created in Chapter 1, Designer, Meet jQuery. Inside the
<body>
tag, we'll start by setting up a simple example that will work even for users with JavaScript disabled. We'll put a list of anchor links to different areas of the page at the top and then wrap each of our content sections in adiv
block with an ID, as shown in the following code:<header class="content"> <h1>Noble Gases</h1> <p>Odorless, colorless, monatomic gases with very low chemical reactivity</p> </header> <ul id="tabs"> <li><a href="#he">He</a></li> <li><a href="#ne">Ne</a></li> <li><a href="#ar">Ar</a></li> <li><a href="#kr">Kr</a></li> <li><a href="#xe">Xe</a></li> ...