๐ŸŽจ Class 3 โ€” Continue Inline Styling

Topic 1 ยท HTML & CSS โ€” 3 hours ยท Recap, nav bars, buttons, tables, accessibility & colour

Part 1 ยท Recap & Inspect Tool

We started by recapping last week โ€” building a page from scratch and using inline styling. Don't assume you remember it perfectly; rebuilding is the best way to lock it in.

Then we explored some live websites with the browser's Inspect tool (right-click โ†’ Inspect). This lets you see the HTML and CSS behind any website โ€” a free education on how the web is built.

๐Ÿ” Try it: Visit any site, right-click anything on the page, and choose Inspect. The panel that opens shows the HTML structure on the left and the CSS rules applied to whatever you've selected.

Building a Nav Bar with <ul>

A navigation bar is just an unordered list of links. We write the HTML first, get it working, then add styling โ€” that way you understand what styling actually does to your raw structure.

<ul>
  <li><a href="index.html">Home</a></li>
  <li><a href="about.html">About</a></li>
  <li><a href="contact.html">Contact</a></li>
</ul>

With inline styling we turn the bullet-point list into a clean horizontal bar:

<ul style="list-style: none; display: flex; gap: 20px; background: #2f9ea0; padding: 12px;">
  <li><a href="index.html" style="color: white; text-decoration: none;">Home</a></li>
  <li><a href="about.html" style="color: white; text-decoration: none;">About</a></li>
  <li><a href="contact.html" style="color: white; text-decoration: none;">Contact</a></li>
</ul>
๐Ÿ“ธ Activity: Build your own nav bar, screenshot it, and share with the class. Make it yours โ€” pick your own colours and link names.

Part 2 ยท Buttons

Buttons are <button> elements. Like the nav bar, we'll write the HTML first then style it. Buttons can be wrapped inside an anchor tag (<a>) to turn them into clickable links.

<a href="contact.html">
  <button style="background: #ff8a3d; color: white; padding: 10px 24px; border: none; border-radius: 4px; font-size: 16px; cursor: pointer;">
    Get in Touch
  </button>
</a>

Your turn: create two buttons. Link each one to a different page or section of your site.

Tables

Tables are great for tabular data โ€” schedules, price lists, comparison charts. The building blocks:

<table style="border-collapse: collapse; width: 100%;">
  <tr>
    <th style="border: 1px solid #1a1a1a; padding: 8px;">Class</th>
    <th style="border: 1px solid #1a1a1a; padding: 8px;">Topic</th>
  </tr>
  <tr>
    <td style="border: 1px solid #1a1a1a; padding: 8px;">1</td>
    <td style="border: 1px solid #1a1a1a; padding: 8px;">Intro to HTML</td>
  </tr>
</table>

Personalise your page with your own table. Make it reflect content that matters to you.

Quick Recap Checklist

๐Ÿ”— References & Companion Files

Class 3 Reference Sheet (PDF)

Colour Model (PDF)

Hex Colour Model (PDF)

Accessible Design (PDF)

W3Schools CSS

Coolors.co โ€” Colour Palette Generator


Class 3 โ€” Equinim College ยท Front End Web Development ยท 26B