Exercise 1: HTML and Markup Languages
The aims of this lab are:
- to write and, importantly, validate some HTML
- to develop some familiarity with the formal markup language
specifications - both the descriptions and DTDs, and
- to familiarise yourself with some of the developments and issues in markup language
specification and use.
W3Schools
Work through the W3Schools Tutorial: https://www.w3schools.com/html/default.asp
from the start up to HTML Blocks, and also to the section on
HTML Forms.
You don't have to complete every exercise,
but it's a very useful reference and we recommend being familiar with the w3schools tutorials.
Create your own home page
Create an HTML5 home page for yourself. The home
page should contain
- A welcome message
- A photo
- A bullet list of the units you are studying, with each item in the list linked to the Unit Outline for that unit
- A table containing your timetable
You may find it useful to access some of the HTML5 references provided
in the lectures.
Do not be too concerned about page output layout at this stage although you
should use suitable indentation to show the structure of the page
source (see this tutorial for setting up
auto-indentation in VSCode).
Open the page in Firefox, Chrome and Opera to check that it works as
expected. You may also want to have a look at it with Internet Explorer (if you're in Windows).
Depending on your operating system, you can also check it under Safari and SeaMonkey.
Try adding a form to the page. The form should collect a users name, email and date of birth.
Use HTML5 input types, and check that they work in the browser. This W3Schools page has some information on how to use JavaScript to take information from HTML
forms.
Validation
-
Validate your HTML5 page using the validation service at:
https://validator.w3.org/.
-
Try to fix any problems that appear during validation.