← Your first website lesson New set →

Web Worksheet: Your First Website

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

Answer key

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

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