WEEK 2 · JULY 13 · WELCOME TO THE WEB
Your idea.
Now on a page.
Build a landing page for the community project you sketched.
HTML gives it structure. CSS gives it style.
TOFA × Alliance Girls AlumniGrade 10 · Term 3
JULY 13 · MODULE 2
Welcome to the Web · HTML + CSS
WEEK 2 · JULY 13 · WELCOME TO THE WEB
Build a landing page for the community project you sketched.
HTML gives it structure. CSS gives it style.
SKETCH → CONTENT · 5 MIN
Our example: a school opportunities club. Replace its words with yours.
SET UP · 5 MIN
Browser-only? Use CodePen: body content in HTML, styles in CSS. Copy your work to local files before leaving.
BUILD ALONG · INDEX.HTML · 5 MIN
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Opportunities Club</title>
<link rel="stylesheet" href="style.css">
</head>
<body>Hello, community!</body>
</html>
Save and refresh. See “Hello, community!”? You have a webpage.
BUILD ALONG · 7 MIN
<main>
<h1>Find your next opportunity</h1>
<p>Free clubs and challenges for our school.</p>
</main>
Replace “Hello, community!” inside body with this. Change the heading and paragraph for your project.
BUILD ALONG · INSIDE MAIN · 5 MIN
<a href="#join">How to join</a>
<section id="join">
<h2>Join the club</h2>
<p>Ask the club patron at the next school meeting.</p>
</section>
Click the link. Does the URL end in #join? A link navigates; a button performs an action.
BUILD ALONG · STYLE.CSS · 7 MIN
body {
font-family: sans-serif;
background: #f8f4ea;
color: #11172d;
line-height: 1.6;
}
h1 { color: #315ee7; }
body is the selector; color is a property. Change one value, save and refresh.
BUILD ALONG · STYLE.CSS · 5 MIN
main {
max-width: 50rem;
margin: 2rem auto;
padding: 1.5rem;
border: 2px solid #315ee7;
border-radius: 1rem;
}
Padding = space inside the border. Margin = space outside. Try doubling each, one at a time.
DESIGN CHECK · 7 MIN
If you add an image, describe its purpose with alt text. Use only images you have permission to share.
PEER REVIEW · 8 MIN
Review the page, not the person. Swap roles halfway.
IMPROVE · 8 MIN
Explain what improved for the visitor—not just what changed in the code.
THIS WEEK · YOUR DELIVERABLE
← → to navigate · F fullscreen
Slide 1 of 12