January 2018
Intermediate to advanced
340 pages
8h 6m
English
Headings are the primary structural elements that define the hierarchy of a web page, with <h1> being the top level and <h6> being the lowest or deepest level of the hierarchy. The title, defined in the <title> tag, of an HTML page is what gets displayed in the browser title bar, and it is not part of the rendered page.
By listing the title and headings, you can quickly get an idea of what the topic of the page is, assuming that they properly formatted their HTML. There is only supposed to be one <title> and one <h1> tag, but not everyone conforms to the standards.
This program loads a web page and then prints the title and all headings to standard output. Try running this program against a few URLs and see ...
Read now
Unlock full access