Web Worksheet: Your First Website
Code tip (One file per job): Tags → index.html; selector { … } → style.css; let, alert, console.log → script.js. Plan → write the HTML → add CSS → test in a browser → publish. Use small letters and dashes in file names; save and refresh to see changes.
NameDateTime takenScore ___ / 40
- 1.🚀 You change your code. What should you do to see the change? (a) save and refresh (b) delete the file (c) switch off the PC (d) rename the folder
- 2.True or false: .box { padding: 8px; } goes in style.css. (a) False (b) True
- 3.🚀 Which file should this code go in: p { color: red; } (a) script.js (b) style.css (c) index.html
- 4.🚀 Which file should this code go in: <a href="a.html">Go</a> (a) style.css (b) script.js (c) index.html
- 5.🚀 Which file should this code go in: <img src="cat.png"> (a) style.css (b) script.js (c) index.html
- 6.🚀 Which file is best for the colours and fonts? (a) photo.jpg (b) style.css (c) script.js (d) index.html
- 7.True or false: p { color: red; } goes in index.html. (a) True (b) False
- 8.🚀 Which file should this code go in: console.log(5 + 2); (a) style.css (b) index.html (c) script.js
- 9.🔢 To build and share your first web page, which comes first: “publish it online” or “test in a browser”? (a) publish it online (b) test in a browser
- 10.🚀 Which file is best for code that reacts to clicks? (a) index.html (b) notes.txt (c) script.js (d) style.css
- 11.🚀 Which file should this code go in: let score = 0; (a) style.css (b) index.html (c) script.js
- 12.🚀 What is the home page file of a website usually called? (a) main.png (b) home.css (c) index.html (d) start.js
- 13.🚀 Which file should this code go in: <h1>My Site</h1> (a) index.html (b) style.css (c) script.js
- 14.True or false: <ul><li>Art</li></ul> goes in index.html. (a) False (b) True
- 15.True or false: alert(score); goes in script.js. (a) True (b) False
- 16.🚀 Which file should this code go in: body { margin: 0; } (a) index.html (b) style.css (c) script.js
- 17.True or false: h1 { font-size: 32px; } goes in script.js. (a) False (b) True
- 18.True or false: console.log(5 + 2); goes in style.css. (a) False (b) True
- 19.True or false: score = score + 1; goes in script.js. (a) False (b) True
- 20.True or false: <img src="cat.png"> goes in index.html. (a) False (b) True
- 21.🚀 Which file should this code go in: score = score + 1; (a) index.html (b) script.js (c) style.css
- 22.🔢 To build and share your first web page, what comes right after “plan what to show”? (a) write the HTML (b) publish it online (c) test in a browser (d) add CSS styles
- 23.🔢 To build and share your first web page, which comes FIRST? (a) add CSS styles (b) test in a browser (c) plan what to show (d) write the HTML
- 24.🚀 Should file names have spaces, like my page.html? (a) Yes (b) No
- 25.🚀 Which file should this code go in: <ul><li>Art</li></ul> (a) index.html (b) style.css (c) script.js
- 26.🚀 Which program lets you see your web page while you build it? (a) a web browser (b) a music player (c) a calculator (d) a photo viewer
- 27.🔢 To build and share your first web page, which comes first: “publish it online” or “plan what to show”? (a) publish it online (b) plan what to show
- 28.🚀 Which file should this code go in: h1 { font-size: 32px; } (a) script.js (b) index.html (c) style.css
- 29.True or false: <p>Hello!</p> goes in style.css. (a) True (b) False
- 30.🚀 Which file should this code go in: <p>Hello!</p> (a) script.js (b) style.css (c) index.html
- 31.🔢 To build and share your first web page, which comes first: “test in a browser” or “add CSS styles”? (a) test in a browser (b) add CSS styles
- 32.🚀 Which file should this code go in: alert(score); (a) index.html (b) script.js (c) style.css
- 33.🚀 Which tag loads script.js into a page? (a) <link script.js> (b) <script src="script.js"> (c) <js src="script.js"> (d) <a href="script.js">
- 34.True or false: <h1>My Site</h1> goes in style.css. (a) True (b) False
- 35.🔢 To build and share your first web page, which comes first: “write the HTML” or “add CSS styles”? (a) add CSS styles (b) write the HTML
- 36.🚀 Where in index.html does the link to style.css go? (a) after </html> (b) in the footer (c) in the head (d) inside a <p>
- 37.🚀 Which file should this code go in: .box { padding: 8px; } (a) script.js (b) index.html (c) style.css
- 38.🚀 Which file should this code go in: #top { color: blue; } (a) script.js (b) style.css (c) index.html
- 39.🔢 To build and share your first web page, which comes LAST? (a) write the HTML (b) add CSS styles (c) test in a browser (d) publish it online
- 40.True or false: let score = 0; goes in script.js. (a) False (b) True
Answer key
- save and refresh
- True
- style.css
- index.html
- index.html
- style.css
- False
- script.js
- test in a browser
- script.js
- script.js
- index.html
- index.html
- True
- True
- style.css
- False
- False
- True
- True
- script.js
- write the HTML
- plan what to show
- No
- index.html
- a web browser
- plan what to show
- style.css
- False
- index.html
- add CSS styles
- script.js
- <script src="script.js">
- False
- write the HTML
- in the head
- style.css
- style.css
- publish it online
- True
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids