Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <style>
- header
- {
- margin:2px;
- padding:10px;
- height:5em;
- width:80em;
- background-color:gray;
- border: 7px solid lightblue;
- color:white;
- text-align:center;
- }
- nav
- {
- display:block;
- margin:2px;
- padding:10px;
- height:30em;
- width:5em;
- background-color:lightgray;
- border: 7px solid green;
- color:white;
- text-align:center;
- text-align:left;
- <!-- float is used to overlatp two sections -->
- float:left;
- }
- a:hover
- {
- display:block;
- color:white;
- background-color:yellow;
- }
- #student td
- {
- color:white;
- background-color:blue;
- }
- #student tr.alt td
- {
- background-color:yellow;
- color:green;
- }
- </style>
- </head>
- <body>
- <header>
- <h1> Second Lab </h1>
- </header>
- <nav>
- <!-- default display value : inline-->
- <a href="some.html">HOME</a>
- <a href="some.html">CONTACT</a>
- <a href="some.html">HOME</a>
- </nav>
- <section>
- TODAYS OBJECTIVE IS TO LEARN THE BASIC OF CSS
- </section>
- <table id="student">
- <tr>
- <th> ID </th>
- <th> NAME </th>
- <th> CGPA </th>
- </tr>
- <tr>
- <th> 1 </th>
- <th> A </th>
- <th> 4 </th>
- </tr>
- <tr>
- <th> 1 </th>
- <th> A </th>
- <th> 4 </th>
- </tr>
- <tr class="alt">
- <th> 1 </th>
- <th> A </th>
- <th> 4 </th>
- </tr>
- <tr>
- <th> 1 </th>
- <th> A </th>
- <th> 4 </th>
- </tr>
- <tr class="alt">
- <th> 1 </th>
- <th> A </th>
- <th> 4 </th>
- </tr>
- <tr>
- <th> 1 </th>
- <th> A </th>
- <th> 4 </th>
- </tr>
- </table>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement