← Your first website lesson New set →

Web Worksheet: Your First Website

HTML and CSS lesson 29: Your first website · Set 4 · 40 questions
TalentJR

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. 1.🚀 Which file should this code go in: #top { color: blue; } (a) index.html (b) script.js (c) style.css
  2. 2.True or false: alert(score); goes in style.css. (a) True (b) False
  3. 3.True or false: p { color: red; } goes in script.js. (a) False (b) True
  4. 4.🚀 Which file should this code go in: <ul><li>Art</li></ul> (a) script.js (b) style.css (c) index.html
  5. 5.🚀 Which program lets you see your web page while you build it? (a) a web browser (b) a calculator (c) a photo viewer (d) a music player
  6. 6.🚀 Which file should this code go in: score = score + 1; (a) index.html (b) style.css (c) script.js
  7. 7.🔢 To build and share your first web page, which comes first: “add CSS styles” or “test in a browser”? (a) test in a browser (b) add CSS styles
  8. 8.🔢 To build and share your first web page, what comes right after “write the HTML”? (a) plan what to show (b) publish it online (c) add CSS styles (d) test in a browser
  9. 9.🚀 Which file should this code go in: <p>Hello!</p> (a) index.html (b) style.css (c) script.js
  10. 10.🔢 To build and share your first web page, which comes LAST? (a) publish it online (b) test in a browser (c) add CSS styles (d) write the HTML
  11. 11.True or false: <p>Hello!</p> goes in script.js. (a) True (b) False
  12. 12.True or false: p { color: red; } goes in style.css. (a) False (b) True
  13. 13.True or false: .box { padding: 8px; } goes in index.html. (a) False (b) True
  14. 14.🔢 To build and share your first web page, what comes right after “add CSS styles”? (a) write the HTML (b) plan what to show (c) test in a browser (d) publish it online
  15. 15.🚀 Which tag loads script.js into a page? (a) <link script.js> (b) <js src="script.js"> (c) <script src="script.js"> (d) <a href="script.js">
  16. 16.🚀 Which file is best for the colours and fonts? (a) script.js (b) photo.jpg (c) style.css (d) index.html
  17. 17.🚀 Which file should this code go in: console.log(5 + 2); (a) index.html (b) style.css (c) script.js
  18. 18.🚀 What is the home page file of a website usually called? (a) home.css (b) index.html (c) main.png (d) start.js
  19. 19.True or false: alert("Hi"); goes in index.html. (a) False (b) True
  20. 20.🚀 Should file names have spaces, like my page.html? (a) Yes (b) No
  21. 21.🚀 Which file should this code go in: p { color: red; } (a) style.css (b) script.js (c) index.html
  22. 22.🚀 Where in index.html does the link to style.css go? (a) in the footer (b) inside a <p> (c) after </html> (d) in the head
  23. 23.🔢 To build and share your first web page, what comes right after “plan what to show”? (a) publish it online (b) add CSS styles (c) test in a browser (d) write the HTML
  24. 24.🔢 To build and share your first web page, which comes first: “add CSS styles” or “write the HTML”? (a) write the HTML (b) add CSS styles
  25. 25.🔢 To build and share your first web page, which comes FIRST? (a) test in a browser (b) add CSS styles (c) plan what to show (d) write the HTML
  26. 26.🚀 Which file is best for code that reacts to clicks? (a) script.js (b) notes.txt (c) style.css (d) index.html
  27. 27.True or false: <ul><li>Art</li></ul> goes in style.css. (a) False (b) True
  28. 28.🔢 To build and share your first web page, which comes first: “test in a browser” or “publish it online”? (a) publish it online (b) test in a browser
  29. 29.True or false: console.log(5 + 2); goes in script.js. (a) False (b) True
  30. 30.🚀 Which file should this code go in: <a href="a.html">Go</a> (a) script.js (b) style.css (c) index.html
  31. 31.🚀 Which file should this code go in: .box { padding: 8px; } (a) script.js (b) index.html (c) style.css
  32. 32.True or false: alert(score); goes in index.html. (a) True (b) False
  33. 33.🚀 Which file should this code go in: alert(score); (a) script.js (b) style.css (c) index.html
  34. 34.True or false: <ul><li>Art</li></ul> goes in index.html. (a) True (b) False
  35. 35.True or false: alert(score); goes in script.js. (a) True (b) False
  36. 36.🚀 Which file should this code go in: <h1>My Site</h1> (a) style.css (b) index.html (c) script.js
  37. 37.True or false: <ul><li>Art</li></ul> goes in script.js. (a) False (b) True
  38. 38.True or false: alert("Hi"); goes in script.js. (a) True (b) False
  39. 39.🚀 Which file should this code go in: body { margin: 0; } (a) script.js (b) index.html (c) style.css
  40. 40.True or false: <h1>My Site</h1> goes in style.css. (a) False (b) True

Answer key

  1. style.css
  2. False
  3. False
  4. index.html
  5. a web browser
  6. script.js
  7. add CSS styles
  8. add CSS styles
  9. index.html
  10. publish it online
  11. False
  12. True
  13. False
  14. test in a browser
  15. <script src="script.js">
  16. style.css
  17. script.js
  18. index.html
  19. False
  20. No
  21. style.css
  22. in the head
  23. write the HTML
  24. write the HTML
  25. plan what to show
  26. script.js
  27. False
  28. test in a browser
  29. True
  30. index.html
  31. style.css
  32. False
  33. script.js
  34. True
  35. True
  36. index.html
  37. False
  38. True
  39. style.css
  40. False

Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids